Dim Dr_Friend As DataRow = Nothing
Dim Cb As New OleDbCommandBuilder(Da_Friend)
Dr_Friend = Ds_Friend.Tables("friend").NewRow
With Dr_Friend
.BeginEdit()
.Item("f_id") = TxtId.Text
.Item("type_mem") = ComboType.Text
.Item("fname") = TxtFname.Text
.Item("lname") = TxtLname.Text
.Item("phone") = TxtPhone.Text
.Item("mobile") = TxtMobile.Text
.EndEdit()
End With
Ds_Friend.Tables("friend").Rows.Add(Dr_Friend)
Da_Friend.InsertCommand = Cb.GetInsertCommand
Da_Friend.Update(Ds_Friend.Tables("friend"))
Ds_Friend.AcceptChanges()
///////////////////////////////////////////////////////////////////////////////////////////////////////
Dim comUp As New OleDbCommand
Con.Open()
Dim Sql_Up As String = "UPDATE t_friend set birthday=null WHERE f_id = '" & Trim(TxtId.Text) & "'"
With comUp
.CommandType = CommandType.Text
.CommandText = Sql_Up
.Connection = Con
.ExecuteNonQuery()
End With
Con.Close()