Quantcast
Channel: Programming Forums
Viewing all articles
Browse latest Browse all 51036

log in ,sign up system

$
0
0
nothing error to my code but in my logic i think it is have..look at the picture ...and one more in my sign up when i did not type both to the sign up and i click the button it show successfull login but i did not type .
heres my code in login
Public Class login


    Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
        Me.Hide()
        signup.Show()
    End Sub

    Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
     

        If TextBox1.Text = "" And TextBox2.Text = "" Then
            MsgBox("Please Sign Up To Log In")

        ElseIf TextBox1.Text = My.Settings.Username And TextBox2.Text = My.Settings.Password Then

            ProgressBar1.Show()
            ProgressBar1.Increment(1)
            ProgressBar1.Value = ProgressBar1.Maximum
            Timer1.Stop()
            MsgBox("successfull login")
            gradingsystem.Show()

            Me.Hide()
        End If

    End Sub

    Private Sub LinkLabel1_LinkClicked(ByVal sender As System.Object, ByVal e As System.Windows.Forms.LinkLabelLinkClickedEventArgs) Handles LinkLabel1.LinkClicked
        Label5.Hide()
        Label6.Hide()

        changeusername.Show()
     
        Me.Hide()
    End Sub

    Private Sub LinkLabel2_LinkClicked(ByVal sender As System.Object, ByVal e As System.Windows.Forms.LinkLabelLinkClickedEventArgs) Handles LinkLabel2.LinkClicked
        Label5.Hide()
        Label6.Hide()
        changepassword.Show()
        Me.Hide()
    End Sub

    Private Sub login_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
        ProgressBar1.Hide()
        Timer1.Start()
        Label5.Hide()
        Label6.Hide()
    End Sub

    Private Sub Label3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Label3.Click
        Label5.Show()
        Label5.Text = "Your Username Is " & My.Settings.Username & ""

    End Sub

    Private Sub Label4_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Label4.Click
        Label6.Show()
        Label6.Text = "Your Password Is " & My.Settings.Password & ""

    End Sub

End Class


heres my code in signup
Public Class signup

    Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
        My.Settings.Username = TextBox1.Text
        My.Settings.Password = TextBox2.Text
        My.Settings.Save()

        MsgBox("Successfull Sign Up")

        login.Show()
        Me.Hide()
        TextBox1.Text = ""
        TextBox2.Text = ""
    End Sub

    
    Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
        login.Show()
        Me.Hide()
    End Sub
End Class

Viewing all articles
Browse latest Browse all 51036

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>