Skip to content
⌘ NSIS Forum Archive

Restart pc and Goto Safe Mode AUTOMATIC

9 posts

r2du-soft#

Restart pc and Goto Safe Mode AUTOMATIC

Hi guys
I live in Iran and I've started to learn programming language nsis.
Is there any way to do with the programming language that the system is reset and automatically go into Safe Mode?
If the instruction
Thanks
Anders#
You would have to do some research to find how if/how it can be done (CleanBoot entry in the registry?), then we can tell you how to perform the action in NSIS code...
r2du-soft#
hi my friend
I got about this searching.
But I could not do anything, so I'd ask for help
Anders#
Originally Posted by r2du-soft View Post
I got about this searching.
But I could not do anything, so I'd ask for help
This forum is strictly for NSIS questions, you cannot expect us to know every Windows related task.

http://www.pcreview.co.uk/forums/do-...-t4061153.html seems to indicate that msconfig can do it so try running Process Monitor and see which changes it makes to the system. You could also try asking on Stackoverflow...
r2du-soft#
tanks
im find code for set windows to safe mode
but i need convert codes to nsis,can You help me?
my codes is cmd code!
my codes is:


bcdedit /deletevalue {current} safeboot

bcdedit /set {current} safeboot Minimal
bcdedit /set {current} safeboot network
How do I convert this code to NSIS?
tanks
r2du-soft#
taaaaaanks 😉

Worked This:


nsExec::Exec 'bcdedit /deletevalue {current} safeboot'
nsExec::Exec 'bcdedit /set {current} safeboot Minimal'
nsExec::Exec 'bcdedit /set {current} safeboot network'
r2du-soft#
But A Problem!
this Code Not Worken On Windows 64 Bit
I Test This On Windows 7 64Bit


nsExec::Exec 'bcdedit /set {current} safeboot Minimal'
What Work On Windows 86 Bit But Not Work On Windows 64 Bit?!!!
r2du-soft#
yeeeeeeeeee
I Can Fix THIS!!!!!!


!include "x64.nsh"

Section
${DisableX64FSRedirection}
Exec '"bcdedit" /set {current} safeboot Minimal'
Sectionend
Tanks guys