Results 1 to 1 of 1
  1. #1
    Cyberfudger
    Cyberfudger is offline
    Guest
    Join Date
    2012 Nov
    Posts
    2
    Thanks Thanks Given 
    0
    Thanks Thanks Received 
    0
    Thanked in
    0 Posts
    Rep Power
    0

    Cool [Tutorial] How to add local password protection onto your program

    this is where the user creates his username & password:
    Code:
    Public Class Form1
    
        Private Sub Button1_Click(sender As System.Object, e As System.EventArgs) Handles Button1.Click
            Dim temppassword1 As String
            Dim temppassword2 As String
            Dim password As String = My.Settings.Password
            Dim username As String = My.Settings.Username
            temppassword1 = password.Text
            temppassword2 = confirmpassword.Text
            If Not password = ("") Then
                login.Show()
                Me.Close()
                End
            End If
            If password = ("") Then password = confirmpassword.Text
            If username.Text = ("") Then
                MsgBox("Please create a Username!")
            End If
            If confirmpassword.Text = ("") Or confirmpassword.Text = ("") Then
                MsgBox("Please create a Password!")
            End If
            If Not temppassword1 = temppassword2 Then
                MsgBox("Error! Passwords do not match")
            End If
            username = username.Text
            password = confirmpassword.Text
            login.Show()
            Me.Close()
        End Sub
    End Class
    then we create the actual login prompt:
    Code:
    Public Class login
    
        Private Sub Button1_Click(sender As System.Object, e As System.EventArgs) Handles Pass.Click
            If TextBox1.Text = (My.Settings.Password) Then
                MsgBox("Access Granted!")
                'Do Something
                End
            Else
                MsgBox("Access Denied!")
            End If
        End Sub
    
        Private Sub login_Load(sender As System.Object, e As System.EventArgs) Handles MyBase.Load
            label2.text = ("Welcome " & My.Settings.Username & ", Please enter your password!")
        End Sub
    End Class
    And now you're done, Enjoy!

Similar Threads

  1. Collection of local guides
    By Dwar in forum Game Researching Tutorials
    Replies: 4
    Last Post: 2013-03-13, 09:15 AM
  2. [Tutorial] Increase the protection of the altar.
    By Inf_ in forum Aika Bots, Hacks, Cheats
    Replies: 0
    Last Post: 2012-11-23, 07:35 PM
  3. [Request]How can i add X-trap protection
    By P.o.X in forum General Game Research
    Replies: 2
    Last Post: 2012-05-30, 04:36 PM
  4. [Guide] A tutorial of a door with password (PISTONS)
    By Storm! in forum MineCraft Guides, Tutorials
    Replies: 0
    Last Post: 2011-12-20, 05:02 AM
  5. Local wearing high level armor
    By quazatron in forum Aika Online
    Replies: 1
    Last Post: 2011-02-09, 11:16 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •