Jump to content

Dan

Active Members
  • Posts

    21
  • Joined

  • Last visited

Dan's Achievements

Seeker

Seeker (1/7)

0

Reputation

  1. In looking at the script, i found a couple more issues related to " and = characters in names and data. I made the simple change to allow for comments as requested and will check out the remaining issue within the next few days.
  2. Thanks, I changed and updated original post. Note to self: In the future, don't code with a hangover.
  3. So it looks like reg_multi_sz were the only issue. Enclosing the string in quotes is not necessary for reg_sz_multi types. I added an else statement to handle it.
  4. Check out the pstools from sysinterals. PSEXEC will allow you to run an executable (compiled autoit script) on a remote machine. PSKILL will kill a process on a remote machine. http://www.sysinternals.com/ntw2k/freeware/pstools.shtml
  5. It's not a problem. Report them all. I wrote it to help with a specific problem and didn't encounter any of the bugs you found as the .reg files I was working with were strings (without " or \ characters) and dwords. The next time i use this, it will be bug free and able to handle any possible .reg formatting thanks to your diligent testing. Your last post said you had a problem with extra entries being placed in the reg file, I can't duplicate this. Can you give me some more details?
  6. Try this: If NOT ($color = 4802889) Then isweg()
  7. I looked at an old installation package I did for the DSClient and found something that should work for you. If it is available, I always use automation methods provided by the installer rather than send clicks or keystrokes to the installer. Microsoft has a way of changing their installers, but the version of the dsclient i deployed appears to be an iexpress package. The following command line works: I may have renamed the installer to dsclient.exe (too long ago, can't remember). dsclient.exe /q /c:"setup /q" the /c switch allows you to override the install command specified in the iexpress package, so I used this to perform a silent installation by running setup with the /q switch.
  8. your .reg file had a space after the = which are not normally present in an export file. "IPAddress"= "172.16.1.24" You may just need to remove the space from this line to make it work. I exported using regedit /e /a print.reg "hkey......" and it worked. I'm using windows xp pro, that may have something to do with it.
  9. This should get you started: AutoItSetOption("WinTitleMatchMode",2) $IEPATH= "c:\program files\internet explorer\iexplore.exe" & " www.google.com" Run($IEPATH,"",@SW_MINIMIZE) Sleep(3000) ;ControlSend("Microsoft Internet Explorer","","Edit1","www.google.com" & "{ENTER}") ControlSend("Google - Microsoft Internet Explorer","","Internet Explorer_Server1","AutoIt3" & "{ENTER}") Sleep(2000) WinSetState("Google", "",@SW_MAXIMIZE)
  10. This will read your regfile, replace the string and write a new file. Dim $INFILEHANDLE, $OUTFILEHANDLE Dim $DATA, $INFILE, $OUTFILE $INFILE = ".\print.reg" $OUTFILE = ".\newprint.reg" $INFILEHANDLE = FileOpen($INFILE, 0) $DATA = FileRead($INFILEHANDLE,FileGetSize($INFILE)) $DATA = StringReplace($DATA, '"IPAddress"= "172.16.1.24"', '"IPAddress"= "10.10.10.27"') $OUTFILEHANDLE = FileOpen($OUTFILE,2) FileWrite($OUTFILEHANDLE, $DATA) FileClose($INFILE) FileClose($OUTFILEHANDLE)
  11. try: Run("\\servername\temp\install.exe")
  12. rathore, 100 posts, but 30 of them were here finding bugs in my code. It looks like the issue was resolved in the data section, but still existed in the key name. I got that fixed, waiting for you to find something else.
  13. Ok. I added some code to deal with escaped characters (" and \). Let me know if you find anything else.
  14. Fixed the issues idenfied by rathore and this-is-me. Thanks for the help guys. If you find anything else, let me know.
  15. The code was updated with all changes identified in this thread. If you find more issues, let me know.
×
×
  • Create New...