an i ask for help?
what is wrong with my codes
thanks in advance
Sub show1()
Dim DReader As MySqlDataReader
SqlCmd = New MySqlCommand("SELECT * FROM book WHERE accesion_num = '" & b_id & "' ", SqlCon)
DReader = SqlCmd.ExecuteReader
While DReader.Read
accnum.Text = DReader.Item(0)
isbn.Text = DReader.Item(1)
txteditbooktittle.Text = DReader.Item(2)
txteditbookauthor.Text = DReader.Item(3)
txteditbookpiblisher.Text = DReader.Item(4)
DateTimePicker1.Text = DReader.Item(5)
End While
DReader.Close()
End Sub
Sub update1()
Dim DSet As New DataSet
DAdaptr = New MySqlDataAdapter("UPDATE book SET accession_num ='" & accnum.Text & "',isbn='" & isbn.Text & "',tittle='" & txteditbooktittle.Text & "',author'" & txteditbookauthor.Text & "',publisher ='" & txteditbookpiblisher.Text & "',date_of_acquisition ='" & DateTimePicker1.Value & "'where accesion_num='" & b_id & "'", SqlCon)
DAdaptr.Fill(DSet, "book")
MsgBox("Success edit", vbOKOnly)
If MsgBoxResult.Ok = 1 Then
usercontrol.Show()
usercontrol.showUser()
Me.Hide()
End If
End Sub