نوشته شده توسط
mohsenaminzare
اگر نمونه کد رو بذاری شاید بهتر بشه کمک کرد.
اين هم كد :
strSql5 = " SELECT distinct [action-code] FROM u_users,u_useraction"
strSql5 = strSql5 + " WHERE u_users.[user-code] = u_useraction.[user-code] "
If tbpassword.Text <> "" Then
strSql5 = strSql5 + " and password = '" + tbpassword.Text + "' "
EndIf
lbactioncode.DataBindings.Add("Text", dsTest5, "[action-code]")
If lbactioncode.Text = "3" Then
Dim appName AsString = Application.ProductName & "."
Dim mForm AsString = "Form3"
Dim f As studeform = DirectCast(Type.GetType(appName & mForm).InvokeMember(mForm, Reflection.BindingFlags.CreateInstance, Nothing, Nothing, Nothing), Form)
Me.Close()
ElseIf lbactioncode.Text = "2" Then
Dim F As datagather
F = New datagather
F.Show()
Me.Close()
ElseIf lbactioncode.Text = "" Then
Dim F As datagather
F = New datagather
Else
Dim F As profinform
F = New profinform
F.Show()
Me.Close()