I try to use the code but it doesn't work.
'Filter
DataSet11.User.DefaultView.RowFilter = "UserName = '" & TextBox1.Text & "' And Password='" & TextBox2.Text & "'"
Dim dv As DataView
dv = DataSet11.Tables("User").DefaultView
If dv.Count = 1 Then
Dim aForm As New MDIForm()
aForm.Show()
End If
dv.Dispose()
I try MessageBox.Show(dv.Count) and the message box display 0 even i type the correct username and password.
I ran the code on my own machine. I know it works.
Ok, as long as you put in the correct username and password the first time it works. It didn't work when I typed the wrong password, then the right one.