MicahC Posted June 4, 2009 Share Posted June 4, 2009 I am looking for a way to export a registry key to a reg file. The file type really doesn't matter too much just as long as I can read it and email it. Is what im trying to accomplish possible? Micah C Link to comment Share on other sites More sharing options...
froufrou Posted June 4, 2009 Share Posted June 4, 2009 (edited) I am looking for a way to export a registry key to a reg file. The file type really doesn't matter too much just as long as I can read it and email it. Is what im trying to accomplish possible? Micah C ShellExecuteWait("regedit.exe","/e 2.reg HKEY_CURRENT_USER\Software\PopCap",@ScriptDir & "\") This example will export "HKEY_CURRENT_USER\Software\PopCap" to a file named "2.reg" to the same folder you are running the script from.just change "HKEY_CURRENT_USER\Software\PopCap" to what you want and you can change "@ScriptDir & "\" to where you want .And of course you can name it something besides 2.reg as well. Edited June 4, 2009 by froufrou Link to comment Share on other sites More sharing options...
MicahC Posted June 4, 2009 Author Share Posted June 4, 2009 Perfect! This does the trick. I really appreciate your help on this. Link to comment Share on other sites More sharing options...
froufrou Posted June 4, 2009 Share Posted June 4, 2009 No prob! Link to comment Share on other sites More sharing options...
MicahC Posted June 4, 2009 Author Share Posted June 4, 2009 Just another quick question came to mind. Its probrally documented somewhere, but for the sake of time I will ask here. If I want to attache all files in a directory with the *.reg extension how would I go about doing that? Any help is greatly appreciated. ORIGINAL Attachment script: $s_AttachFiles = "" ; the file you want to attach- leave blank if not needed What im thinking... but its not working! $s_AttachFiles = "*.reg" ; the file you want to attach- leave blank if not needed Link to comment Share on other sites More sharing options...
MicahC Posted June 4, 2009 Author Share Posted June 4, 2009 Anyone? If you need more details or information I'm willing explain it more. Link to comment Share on other sites More sharing options...
Inverted Posted June 4, 2009 Share Posted June 4, 2009 Are you crazy ? Read the documentation, what do you mean "for the sake of time" And don't bump after just an hour !!! If you just want to append one file to the other you can read the help file for file operations. Or in one batch command : copy destination.reg firstfile.reg+secondfile.reg+thirdfile.reg Link to comment Share on other sites More sharing options...
MicahC Posted July 28, 2009 Author Share Posted July 28, 2009 Sorry about the bump only after an hour. My bad, I should have done research on my own. I am having troubles copying a reg key. I want to copy: HKEY_CURRENT_USER\Software\Microsoft\Windows NT\CurrentVersion\Windows Messaging Subsystem\Profiles\Outlook\9375CFF0413111d3B88A00104B2A6676 The whole key. For some reason ShellExecuteWait("regedit.exe","/e Outlook.reg HKEY_CURRENT_USER\Software\Microsoft\Windows NT\CurrentVersion\Windows Messaging Subsystem\Profiles\Outlook\9375CFF0413111d3B88A00104B2A6676 ",@ScriptDir & "\") Is not working when attempting to export the key. Any help is appreciated. Link to comment Share on other sites More sharing options...
MicahC Posted July 30, 2009 Author Share Posted July 30, 2009 Does anyone know why I can't copy this key? 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