Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

"YES" to batch file adding .reg info + shutdown options

Status
Not open for further replies.

Antonimo

Technical User
Jun 26, 2003
86
SE
I have a pair of *.reg that will "toggle" settings in the registry. I would like to create a desktop shortcut to the *.reg files that will add the information to the registry. I would like to automatically answer, "yes" to the question,

"Are you sure you want to add the information in C:\...\REGFILE.reg to the regsitry?"

as well as acknowledging the "OK" in the dialogue,

"Information from C:\...\REGFILE.reg has been successfully entered into the registry"

Is there a way to do this?

======================

A full explanation of the situation...

I use a laptop with a UK 88 key Euro layout keyboard. When I am in the office I use a 104 Extended Key Swedish keyboard.
I used to change the keyboard setting from the "Language bar" on the toolbar before shutting down. Recently, I have been unable to do this because of the error,

"An exception occurred while trying to run "shell32.dll,Control_RunDLL input.dll"

I have checked the dll's and tried several "System Restore" operations, but no luck!

In addition, Data Execution Prevention (DEP) is closing down CTFMON.exe every time that I start or re-start the computer (even though I have turned off DEP for "CTF Loader" in DEP exceptions list. (System Properties > Advanced > Performance > Settings > Data Execution Prevention)

(ctfmon.exe is a part of the Microsoft Office suite. It activates the Alternative User Input Text Input Processor (TIP) and the
Microsoft Office XP Language Bar. - quote from
I have to change the keyboard layout so that I can work and the best solution until I resolve the CTFMON and Language Bar problems is to alter the registry entry at [HKEY_CURRENT_USER\Keyboard Layout\Preload] so that a different keyboard layout is used.

The final objective of using the batch files to run this is that I could add the line, "RUNDLL.EXE user,ExitWindows" or %WINDIR%\system32\shutdown.exe -r -t 0" to shutdown Windows and get into the habit of using a single click on one of two icons on the desktop, depending on where I would be using the computer next.

I hope the "fuller" explanation makes what I am tying to achieve easier to understand.

Alternatively, if I could click on ONE desktop icon and then choose which shutdown process to use, that would be great. Even better, if shutdown, re-start and log-off with language change were options, but maybe that is too much to hope for :)
 
If you use the /S switch, this will supress the screens you want to get rid of.

Eg: REGEDIT /S REGFILE.REG

------------------------------------------------------------------------------------
"Life is like a box of chocolates, you never know what you're gonna get!"
------------------------------------------------------------------------------------
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top