tkmadison Posted January 13, 2006 Share Posted January 13, 2006 (edited) Just curious about something....Is it possible to have a computer reboot into safe mode after RunOnceEx finishes, or to have it as a command in ROE?Ideally I'm looking for something like this:finish ROE, reboot to safe mode, delete some files and settings (in which case, can a ROE be run in safe mode or a batch) and then reboot back into "normal" mode? Edited January 13, 2006 by tkmadison Link to comment Share on other sites More sharing options...
Sonic Posted January 13, 2006 Share Posted January 13, 2006 when you use msconfig you can select safe boot .. I think there is a command line or reg tweak to do that unattended ... but when you are in safemode you can't RunOnceEx key is ingored if I rememeber (and all "auto" program at boot are disabled too ...) Link to comment Share on other sites More sharing options...
Synapse Posted January 14, 2006 Share Posted January 14, 2006 it may be possible by editing your boot.ini file following this:http://sniptools.com/tipstricks/add-safe-m...ndows-boot-menubut modify the main one, or add another one and make it default with like 5 seconds timeout. thus when the computer reboots and no ones tehre, it will boot into safemode then have a batchfile delete the files you want, and change the boot.ini file back to normal.. after the nextboot it would then go back into normal mode if you did everything right. Link to comment Share on other sites More sharing options...
maxXPsoft Posted January 14, 2006 Share Posted January 14, 2006 I've done this with 2 .cmd files and a Runoncex entryAt end of the Original cleanup.cmd I run the batch making a new boot.txt and rename the original to .old. The boot.txt to boot.iniIn the .cmd is something like thisI ECHO all the other lines to the boot.txt and then this"for /F " & Chr(34) & "tokens=*" & Chr(34) & " %%S in ('FINDSTR /B " & Chr(34) & "multi" & Chr(34) & " %systemdrive%\boot.ini') do ECHO %%S /safeboot:minimal>> %systemdrive%\boot.txt"Thats the way I wrote it in VB and some things may not ne needed in yours.That will make it boot to Safe on next boot.At end of this .cmd I reboot.Then it boots in Safe and does what it needs and I add the runoncex to set the Orig.boot.ini back when It reboots with 2nd .cmdActually used this to copy the wpa.dbl and reboot to Safe to overwrite them then reboot. Link to comment Share on other sites More sharing options...
Rico.JohnnY Posted January 14, 2006 Share Posted January 14, 2006 You can use a tool called BootSafe which is a freeware.But it doesn't seem to support command line options,maybe you can use autoit with it to achieve that purpose. Link to comment Share on other sites More sharing options...
Yzöwl Posted January 14, 2006 Share Posted January 14, 2006 You could try this compiled batch file!It was coded for Windows XP and can not be run successfully by Limited usersSafeBoot.zip Link to comment Share on other sites More sharing options...
MOONLIGHT SONATA Posted February 20, 2006 Share Posted February 20, 2006 Dear Yzöwl,downloaded it and used. very nice. however, it works perfectly in one partition, i mean it reboots to safemode directly. In another partition, it reboots and multi-boot menu waits as per time-out value set. What's there in the batch file? could you please discuss more with your code? BTW, i think you compiled it with QBFC. Am i right?The way your .exe file boots perfectly in case of one partition, i've some idea to grow it into a better solution. please discuss how your batch does the job.Thanks.@MOONLIGHT SONATA Link to comment Share on other sites More sharing options...
Yzöwl Posted February 20, 2006 Share Posted February 20, 2006 I'm not sure I understand your problem, until I can find out more, you could try this version!SafeBoot.zip Link to comment Share on other sites More sharing options...
MOONLIGHT SONATA Posted February 22, 2006 Share Posted February 22, 2006 (edited) I'm not sure I understand your problem, until I can find out more, you could try this version!Yzöwl,Here i explain:1. safeboot.exe should boot the XP installation from which it's executed. I mean, if it's executed from 1st partition, it should boot that partition's XP into safe mode. If it's from 2nd partition, you understand what i mean. Hereby i suppose Windows XP resides in both the partitions as safeboot.exe works in only XP environ.Saying such i mean it'll read ARC Path Naming Conventions in boot.ini and modify it as per its need.It may have to change the default=multi(0)disk(0)rdisk(0)partition(x)\WINDOWS for the purpose of booting the current partition into safe mode.This way your safeboot.exe justifiedly frees itself from booting a single partition in a hard disk and rightly implements itself for the purpose of a multi-boot scenario.Is it possible?2. With enormous hope i assume that it's possible. If your answer is yes, i come to the final stage of my idea. Imagine how OEMs brand their Windows XP by including a menu item below "RUN" command (if my memory is short, pardon me) which says like "How do you like our Customized Windows XP?". This item can be linked to any EXE or HTML or any Mail Address. I want it should look just like below in my machine(or any members machine):"Trust Our Man Friday 'Yzöwl' For SafeBoot Needs"I hope i've not hurt you by saying so. I say it as that's what my heart wished to say.Thanks.@MOONLIGHT SONATA Edited February 22, 2006 by MOONLIGHT SONATA Link to comment Share on other sites More sharing options...
Yzöwl Posted February 22, 2006 Share Posted February 22, 2006 (edited) So what I think you're saying is that you need a method which knows that in a multiboot environment, the currently running OS is the one on partition 2 or partition 1 etc.I did produce one for such an eventuality, which I will try to dig out, edit and post in the next day or two...[Edit]I had cause to revisit this thread and noticed that I hadn't posted my 'dug out' one!I've checked it and recompiled it, just to check the code and ensure it still functions.If you see this Mr Moonlight, give it a shot and post back.SafeBoot.zip Edited August 13, 2008 by Yzöwl Link to comment Share on other sites More sharing options...
MOONLIGHT SONATA Posted February 22, 2006 Share Posted February 22, 2006 (edited) Thanks. I knew that you'll understand what i mean (of course only when i give my piece of mind. You cann't do thought-reading; or do i suppose otherwise!)Branding your safeboot.exe into start menu will give me utmost pleasure. I want it to go into every uA install that i do in future.waiting for your kind response. Edited February 22, 2006 by MOONLIGHT SONATA Link to comment Share on other sites More sharing options...
MOONLIGHT SONATA Posted March 6, 2006 Share Posted March 6, 2006 Dear Yzowl, Is that really possible? Of late i miss any input from you, whatsoever. Whenever you find an iota of time in your busy schedule, just find time to look into it. till then, i await to hear from you..Thanks.*****MOONLIGHT SONATA 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