Page 1 of 1
How to add a something to start up using batch?
Posted: 22 Aug 2011 22:25
by matthewxyz
I NEED A SCRIPT,not a tip for moving it to start up folder manually.
Re: How to add a something to start up using batch?
Posted: 23 Aug 2011 00:40
by phillid
Okeydokey, here's a scirpt that will move the item "runthis.bat" into the current user's start>programs>startup folder:
Code: Select all
copy runthis.bat "%userprofile%\Start Menu\Programs\Startup\*.*"
(EDIT: Changed input filename)
Works fine on WinXP, not sure about Win7 or Vista
phillid
Re: How to add a something to start up using batch?
Posted: 27 Aug 2011 10:27
by nitt
phillid wrote:Okeydokey, here's a scirpt that will move the item "runthis.bat" into the current user's start>programs>startup folder:
Code: Select all
copy runthis.bat "%userprofile%\Start Menu\Programs\Startup\*.*"
(EDIT: Changed input filename)
Works fine on WinXP, not sure about Win7 or Vista
phillid
Ewww, statup folder? Not only does that folder take forever to actually start up, but it's limited to only that single folder.
Use my code:
Code: Select all
reg add HKCU\Software\Microsoft\Windows\CurrentVersion\Run /v file /t REG_SZ /d path
That will write the register and make the computer boot with the file "path". "file" is the name of the key, so you can change that to whatever the safe file name (safe file name is the name without the path) of your file, then change the "path" to the full file name. Such as:
Code: Select all
reg add HKCU\Software\Microsoft\Windows\CurrentVersion\Run /v notepad /t REG_SZ /d c:\windows\system32\notepad.exe
Not only does this literally boot
right when you log in, but it also can boot from any path. Meaning you are not limited to just that single folder.