dennis123123 Posted August 7, 2005 Share Posted August 7, 2005 Hi. I am making an unattended xp installation disc. Please tell me if there is a way to do some tasks automatically when it is in windows with the taskbar etc. I tried GuiRunOnce but that is too early - before the desktop appears. Also, is it possible to do this without the $OEM$ folders, because OEMPreinstall is off so that I can use SATA from floppy discs successfully.Thanks. Link to comment Share on other sites More sharing options...
Ghost82 Posted August 7, 2005 Share Posted August 7, 2005 Hi. I am making an unattended xp installation disc. Please tell me if there is a way to do some tasks automatically when it is in windows with the taskbar etc. I tried GuiRunOnce but that is too early - before the desktop appears. Also, is it possible to do this without the $OEM$ folders, because OEMPreinstall is off so that I can use SATA from floppy discs successfully.Thanks.<{POST_SNAPBACK}>depending on the tasks you wish to do you could create a shorcut to a .cmd file or some program in the Startup folder. Question remains what do you want to do? Link to comment Share on other sites More sharing options...
dennis123123 Posted August 7, 2005 Author Share Posted August 7, 2005 Running a cmd would be OK, but the question remains, how do I put it in the startup folder, to be only run once? Thanks for the reply. Link to comment Share on other sites More sharing options...
Ghost82 Posted August 7, 2005 Share Posted August 7, 2005 put "del start.cmd" at the end of the file maybe? Link to comment Share on other sites More sharing options...
dennis123123 Posted August 7, 2005 Author Share Posted August 7, 2005 ok, but how do I get it there in the first place without $OEM$ folders? Link to comment Share on other sites More sharing options...
Ghost82 Posted August 7, 2005 Share Posted August 7, 2005 then you've got a real problem...but why not use $OEM$-Folders? the file has to be there before first boot otherwise it's not going to work. Link to comment Share on other sites More sharing options...
dennis123123 Posted August 7, 2005 Author Share Posted August 7, 2005 I need OEMPreinstall to =0 to make SATA drivers from a floppy disc work, therefore I cant use the $OEM$ folders. If I did, and put OEMPreinstall=1, then "press f6 to install drivers" doesnt work.Any ideas please? Link to comment Share on other sites More sharing options...
jbm Posted August 7, 2005 Share Posted August 7, 2005 one way to do it would be to use detachedprogram in winnt.sif.Put your copycmd.cmd and startup.cmd in the i386 folder on the CD.the 1 after the 3_ tells setup to copy the file to the windows dir.You can change that if needed, just check in the txtsetup.sif.but it has to be a sub of the windows dir.edit txtsetup.sif[SourceDisksFiles]bootvid.dll = 1,,,,,,3_,2,0,0,,1,2copycmd.cmd = 1,,,,,,3_,1,0,0,,1,2startup.cmd = 1,,,,,,3_,1,0,0,,1,2Add this to your winnt.sif file.[GuiUnattended] DetachedProgram="%windir%\copycmd.cmd"copycmd.cmdxcopy /Y startup.cmd "%SystemDrive%Documents and Settings\All Users\Start\startu Menu\Programs\Startup\"copycmd.cmd will be run at t39 during setup. Link to comment Share on other sites More sharing options...
dennis123123 Posted August 7, 2005 Author Share Posted August 7, 2005 Wow! Thanks for the indepth reply, however, it doesnt work! both files do get copied to the windir thru txtsetup.sif, but startup.cmd doesnt get put in the startup folder, and obviously does not start. Any suggestions/corrections/hints are appreciated, and thanks for that guide, would have been better if it worked first time! Shame...Thank-you! Link to comment Share on other sites More sharing options...
Godfatha Posted August 7, 2005 Share Posted August 7, 2005 do it the runonce method way...as u mentioned detached method works for u...use that one, but instead of copy method use a registry key (run or runonceex), if u use runonceex it'll start only once, if u use run its like the startup folder (a millisecond earlier tho..). but since u wanna run only one time that doesn't matter. So just do a reg add on the batch file or import a pre-done regfile to your needs. that should work for sure (just look out if u have spaces or placeholders in the reg command (something like %systemdrive%) these are supported by reg.exe tho (somewhere in the msfn guides was a guide for that too...))so u would copy 2 batchfiles via detached way, execute one thru guirunonce, that one would import (or create) registry entries on HCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Run (one guide would be here: http://unattended.msfn.org/intermediate/me...s/runonceex.htm or u use "REGEDIT /S REGFILE.reg", where REGFILE.reg consists of the entries that have to be added to your run key).the path should point at the 2nd batchfile, that would be executed when the PC starts. as far as i know the HCU does support a run key and so it would startup after the pc booted. The thing i am not 100% sure is, if the HCU is working already, because ur username never logged on before, a workaround could be a batchfile executed in HKLM\...\runonce\setup, which is executed after user logs on (read here: http://www.windowsnetworking.com/kbase/Win...pLocations.html. but its strange that the copy method doesn't work for you tho... try the registry way (even tho its complicated and sucks... )regards-T Link to comment Share on other sites More sharing options...
gamehead200 Posted August 7, 2005 Share Posted August 7, 2005 do it the runonce method way...as u mentioned detached method works for u...use that one, but instead of copy method use a registry key (run or runonceex), if u use runonceex it'll start only once, if u use run its like the startup folder (a millisecond earlier tho..). but since u wanna run only one time that doesn't matter. So just do a reg add on the batch file or import a pre-done regfile to your needs. that should work for sure (just look out if u have spaces or placeholders in the reg command (something like %systemdrive%) these are supported by reg.exe tho (somewhere in the msfn guides was a guide for that too...))so u would copy 2 batchfiles via detached way, execute one thru guirunonce, that one would import (or create) registry entries on HCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Run (one guide would be here: http://unattended.msfn.org/intermediate/me...s/runonceex.htm or u use "REGEDIT /S REGFILE.reg", where REGFILE.reg consists of the entries that have to be added to your run key).the path should point at the 2nd batchfile, that would be executed when the PC starts. as far as i know the HCU does support a run key and so it would startup after the pc booted. The thing i am not 100% sure is, if the HCU is working already, because ur username never logged on before, a workaround could be a batchfile executed in HKLM\...\runonce\setup, which is executed after user logs on (read here: http://www.windowsnetworking.com/kbase/Win...pLocations.html. but its strange that the copy method doesn't work for you tho... try the registry way (even tho its complicated and sucks... )regards-T<{POST_SNAPBACK}>I was just going to mention this! I use it to change my resolution and other stuff on first startup! Link to comment Share on other sites More sharing options...
jbm Posted August 7, 2005 Share Posted August 7, 2005 Wow! Thanks for the indepth reply, however, it doesnt work! both files do get copied to the windir thru txtsetup.sif, but startup.cmd doesnt get put in the startup folder, and obviously does not start. Any suggestions/corrections/hints are appreciated, and thanks for that guide, would have been better if it worked first time! Shame...Thank-you!<{POST_SNAPBACK}>There was a big error in my copycmd.cmd change it to eitherxcopy /Y startup.cmd "%ALLUSERSPROFILE%\Start Menu\Programs\Startup\"orxcopy /Y startup.cmd "%USERPROFILE%\Start Menu\Programs\Startup\" Link to comment Share on other sites More sharing options...
dennis123123 Posted August 8, 2005 Author Share Posted August 8, 2005 Right, I havent yet tried the new copycmd, but the reg entries dont work either - the files get put in the windir thtough txtsetup again, but it looks like the problem is DetachedProgram. Any more ideas? Ill try the new copycmd today. Link to comment Share on other sites More sharing options...
MHz Posted August 8, 2005 Share Posted August 8, 2005 Just use Cmdlines.txt to execute the cmdfile, instead of DetachedProgram. OEMPreinstall does not stop Cmdlines.txt from executing. Cmdlines.txt will execute even without a Winnt.sif. Link to comment Share on other sites More sharing options...
jbm Posted August 8, 2005 Share Posted August 8, 2005 Just use Cmdlines.txt to execute the cmdfile, instead of DetachedProgram. OEMPreinstall does not stop Cmdlines.txt from executing. Cmdlines.txt will execute even without a Winnt.sif.<{POST_SNAPBACK}>If I under stand right I thought the problem was he wants the .cmd file orwhatever to run after the taskbar appears. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now