Many thanks for the reply, however, this does not prevent the hybernate file from being wriiten to HDD/SSD during setup, but, rather disables hyberfil and deletes the hybernate file post install; correct? I want to completely disable the file from being written at all in the first place at ant time during set up. I personally have a FirstLogon cmd that merges a few reg files (including the HibernateEnabled to disabled one) which effectively does the same thing. Actually, I wonder if I just run this as a Synchronous cmd in pass 4 "Specialise" from autounattend thusly: Code: CLS @echo off TITLE Disable Hibernate powercfg -h off powercfg /hibernate off EXIT Would that work do you think and prevent hyberfil from loading at all? Thanks
Shenj code did it, just for cmd prompt window: Code: Windows Registry Editor Version 5.00 [HKEY_CLASSES_ROOT\Directory\shell\cmd] "Icon"="imageres.dll,-5323" "MUIVerb"="@shell32.dll,-37415" ;Alternative text ;"MUIVerb"="@shell32.dll,-22022" "Position"="Bottom" "SubCommands"="Windows.MultiVerb.cmd;Windows.MultiVerb.cmdPromptAsAdministrator" [HKEY_CLASSES_ROOT\Directory\Background\shell\cmd] "Icon"="imageres.dll,-5323" "MUIVerb"="@shell32.dll,-37415" ;Alternative text ;"MUIVerb"="@shell32.dll,-22022" "Position"="Bottom" "SubCommands"="Windows.MultiVerb.cmd;Windows.MultiVerb.cmdPromptAsAdministrator" However, I had to delete manually this entries to make it work entirely: Code: [HKEY_CLASSES_ROOT\Directory\shell\cmd] @="@shell32.dll,-8506" "NoWorkingDirectory"="" "Extended"="" and [HKEY_CLASSES_ROOT\Directory\background\shell\cmd] @="@shell32.dll,-8506" "NoWorkingDirectory"="" "Extended"="" Then I need a script to automate this entirely, please. btw, it only works on folders not drives.
This way it works perfectly for me: Code: Windows Registry Editor Version 5.00 [HKEY_CLASSES_ROOT\Directory\shell\runas] "Icon"="imageres.dll,-5323" "MUIVerb"="@shell32.dll,-37415" ;Alternative text ;"MUIVerb"="@shell32.dll,-22022" "Position"="Bottom" "SubCommands"="Windows.MultiVerb.cmd;Windows.MultiVerb.cmdPromptAsAdministrator" [HKEY_CLASSES_ROOT\Directory\Background\shell\runas] "Icon"="imageres.dll,-5323" "MUIVerb"="@shell32.dll,-37415" ;Alternative text ;"MUIVerb"="@shell32.dll,-22022" "Position"="Bottom" "SubCommands"="Windows.MultiVerb.cmd;Windows.MultiVerb.cmdPromptAsAdministrator" [HKEY_CLASSES_ROOT\Drive\shell\runas] "Icon"="imageres.dll,-5323" "MUIVerb"="@shell32.dll,-37415" ;Alternative text ;"MUIVerb"="@shell32.dll,-22022" "Position"="Bottom" "SubCommands"="Windows.MultiVerb.cmd;Windows.MultiVerb.cmdPromptAsAdministrator"
Gonna try right away mate!!! btw they are intended for what? Oh I saw the commands sorry. Ed.- s1ave77 I don't see the commands to delete the following entries (by default) that I've already talked about and need to be deleted to make the tweak to work: Code: [HKEY_CLASSES_ROOT\Directory\shell\cmd] @="@shell32.dll,-8506" "NoWorkingDirectory"="" "Extended"="" and [HKEY_CLASSES_ROOT\Directory\background\shell\cmd] @="@shell32.dll,-8506" "NoWorkingDirectory"="" "Extended"=""
As i realized your post yesterday i edited Shenjs script accordingly, so no need to delete them . Also i use slighly different reg keys. BTW: edited previous post slightly.
@s1ave77 Done. You are the man too, hahahahaha. Task accomplished!!!! Everything working fine as expected
Going to put your solution at OP to share knowledge for anyone who needs it. Thanks again friend. Giving proper credits for all of you who helped, thanks all of you.
Best is i already had this but must have screwed as i could find again . So i started over, fortunately you gave the right hint regarding the unnessessary lines (which drove me nearly mad). Rest was only combining the correct pieces again. This time i saved this nice trick properly .
Losing info/data happens to anyone, even the best like you. It is important this kind of context menu option to avoid the stupid "cd.." command to navigate until you reach the desired folder... duh! Sorry for the headache I caused... lol
Luckily no headaches involved ... good moment for a little challenge, got ready maintaining my Win 8.1 WIMs .
Hey ! I know we can delete startup programs if we clear all the the keys in HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Run Q1 - But how i can do if i don't want to deleted them, but just if i want to DISABLED THEM like on this capture ??? : i.imgur.com/r6c3VaA.jpg Q2 - Have also a trick to disabled all non-microsoft services with a batch or registry way for a lambda computer ??? : i.imgur.com/c0X0gbm.jpg Of course it suppose we don't know already about the names of the non-microsoft services we want to disabled, else i think it's easy with the "sc" command ... Thanks