It's been a looong time for me, and back in the day when we needed batch files, I had a boss who did most of the batch stuff, so I was never very practiced. Very simple: I need a sample batch that will install a .exe and then run a .reg to change several registry settings. Can someone post an example? Much thanks.
never had to execute a .reg file but the following should work for .exe copy and paste below into .bat file (via notepad or notepad++) cd c:\program files\mozilla firefox.exe exit
Is your .exe the installer? There's probably documentation for running the .reg stuff from the command line. If the .exe is the installer...check the installer documentation for command line arguments...as you'll probably want to run it in silent mode. Same thing with the .reg stuff. Just an offshoot guess... bat file would look something like this (assuming the .exe is the installer)... installer.exe /S registry.reg /S with /S's being the silent install arguments. Otherwise, the installer and registry installer will probably throw up message prompts and pause while waiting for input.
Thanks for the help. I'm building an install package and sending it out to a bunch of techs. Based on experience, I need to assume they're all idiots. I'm going to put one folder on a USB drive. They will then copy the USB drive to the root of their PCs. The folder will contain the setup.exe and the regkey.reg. They will then run the batch file from within the folder. Trying to make it as foolproof as possible.
1. Build a top-down scheme of how you want the BAT file to run. 2. Create it. 3. Test it. 4. Test it. 5. Test it on someone else's machine. 6. Make your final corrections. 7. Document it and write everything down. 8. Send it and ask for lots of feedback. Nice attitude. This will get you FAR in life, sir. Man, stop thinking like that. You're only hurting yourself. I am serious. Don't ever let anyone outside 'the family' know what you're thinking (much less if you're calling them "idiots"). Won't help you much.
Steps 1-7 are a given. Step 8 and the subsequent commentary...It's been my experience with this group of people that you have to assume that they know nothing. They are government employees.