Instructables

Step 1: Making the screen (part1)

Here I'm going to show you the first part of the screen lock ..
the first pic is the window that comes up when you run my screen lock.

on this you can set the password .. i made it so you have to set it every time so you could never forget it. Also so my program is only 1 file.

you also have the option to see it to see through .. this is just so the lock screen is slightly see through. So you can see your desktop pic faded out.

now here is how i did it:
for the password:


Private Sub TextBox1_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles TextBox1.TextChanged
If TextBox1.Text = Form1.TextBox1.Text Then

Dim process As System.Diagnostics.Process = Nothing
Dim psi As New ProcessStartInfo
psi.UseShellExecute = True
psi.FileName = "taskkill.exe"
psi.Arguments = "/F /IM taskmgr.exe"
process = System.Diagnostics.Process.Start(psi)

Shell("explorer.exe")

Form1.Close()
End If
End Sub

what this does is checks to see if the text in textbox1 is equal to the text that you set on the first window. Then if it does it task kills task manager if it was running, And restarts explorer.exe.

here is the see through bit:


Private Sub Form2_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load

Dim process As System.Diagnostics.Process = Nothing
Dim psi As New ProcessStartInfo
psi.UseShellExecute = True
psi.FileName = "taskkill.exe"
psi.Arguments = "/F /IM explorer.exe"
process = System.Diagnostics.Process.Start(psi)

If Form1.CheckBox1.Checked = True Then
Me.Opacity = 0.5
Else
Button1.Show()
End If
End Sub

This piece of script will task kill explorer.exe so even if someone gets past my screen lock they will not be able to do anything!
then it checks to see if the 'see through' box has been checked. If it has it sets opacity to 0.5.
If not then it shows the change background button.
 
Remove these adsRemove these ads by Signing Up