Follow the code:
code:vb
If mesge = vbOK Then
rs.Open "select * from empdetail where name = '" & mName & "'", conn, adOpenStatic, adLockOptimisti c
txtid.Text = rs!id
txtid.Enabled = False
Else
txtid.Text = ""
txtid.Enabled = True
End If
rs.Close
Set rs = Nothing
starts from if the control not moving to else?
What's wrong with the code? Anybody please explain.
code:vb
If mesge = vbOK Then
rs.Open "select * from empdetail where name = '" & mName & "'", conn, adOpenStatic, adLockOptimisti c
txtid.Text = rs!id
txtid.Enabled = False
Else
txtid.Text = ""
txtid.Enabled = True
End If
rs.Close
Set rs = Nothing
starts from if the control not moving to else?
What's wrong with the code? Anybody please explain.
Comment