将不会读取DateTimePicker1,但会读取另一个函数。我想知道此代码中的问题是什么。
Public com As New MySql.Data.MySqlClient.MySqlCommand
Public da As New MySql.Data.MySqlClient.MySqlDataAdapter
Public dr As MySql.Data.MySqlClient.MySqlDataReader
Public dt As New DataTable
Public ds As DataSet
Private Sub frmupdateaccount_Load(sender As Object, e As EventArgs) Handles MyBase.Load
Dim READER As MySql.Data.MySqlClient.MySqlDataReader
Dim query As String
con.Open()
query = "Select * from user_tbl where userid='" & txtuserid.Text & "'"
com = New MySql.Data.MySqlClient.MySqlCommand(query, con)
READER = com.ExecuteReader
While READER.Read
txtcontactnumber.Text = READER.GetString("contactnumber")
cbxgender.Text = READER.GetString("gender")
datetimepicker1.Text = READER.GetString("dateofbirth")
End While
con.Close()
End Sub