Author | Message | ||
---|---|---|---|
Ghا’][‘ Clone Posts: 2 | Hi to all.I realy need some help here .Im just started to learn VB6.I protected a form2 with a password protected form one .i did it not much of a problem here but . i want to make a script that if someone inserts a wrong password to.... shout down his computer Private Sub accept_Click() If password.Text = "ghostdesign" Then MsgBox "Password correct!" Unload Me Form2.Show Else MsgBox "Dont waste my time!" MsgBox "1" MsgBox "2" MsgBox "3" Dim wshshell Set wshshell = wscript.CreateObject("WScript.Shell") wshshell.Run "shutdown -s -t 5" End If End Sub Something like this.The password is working when i put the real psw it sends me to the next form but when i insert a worng password :cry: crashes . It says to me something like this Run -time error "424'' Object required :?: I most insert a new commponent from Projects - Commponents ?? .If yes please tell me what? Best Regards Ghost ps:nice site and forum (very usefull) | ||
dzadzuks Ametuar Posts: 135 |
this is all u need.. | ||
C0D3Z3R0 Pro Posts: 166 | He found out how to do it when he had posted on my forums, I'll post the solution here soon | ||
Ghا’][‘ Clone Posts: 2 | Thanks now it works |