Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.
One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.
This is my button1_click event: Dim breturn As Boolean breturn = verifyuser(loginname.Text, password.Text) If breturn = True Then Dim ticket As FormsAuthenticationTicket = New FormsAuthenticationTicket(loginname.Text, False, 5000) FormsAuthentication.RedirectFromLoginPage(loginname.Text, False) Else feedback.Text = "The Login Name and Password you typed in doesn't match our records" End If This is my "verifiyuser" function: Protected Function verifyuser(ByVal username As String, ByVal password As String) As Boolean Dim sdr As System.Data.SqlClient.SqlDataReader Dim con As SqlConnection = New SqlConnection("myconnectionstring) Dim breturn As Boolean Dim cmd As SqlCommand = New SqlCommand("login", con) cmd.CommandType = Data.CommandType.StoredProcedure cmd.Parameters.Add("@cologin", NVarChar, 255).Value = loginname cmd.Parameters("@cologin").Value = loginname con.Open() sdr = cmd.ExecuteReader While sdr.Read If sdr("Password") = password Then breturn = True End If End While Return breturn End Function This is my stored Procedure: @cologin as nvarchar (max) AS select * from members where cologin = @cologin RETURN
Add your voice to the tech community where 5M+ people just like you are talking about what matters.
|VB6 calling COM DLL written in Visual Studio 2003||6||53|
|Web page design problem||3||39|
|Learning About The VB.NET TableLayoutPanel Control||5||38|
|Disable the weekends on datepicker control||6||50|
Join the community of 500,000 technology professionals and ask your questions.