Jump to content

Keithdib

Active Members
  • Posts

    26
  • Joined

  • Last visited

Profile Information

  • Location
    UK

Keithdib's Achievements

Seeker

Seeker (1/7)

0

Reputation

  1. If you use "wsname" all you need to do is run as follows wsname.exe /N:$SERIALNUM or wsname.exe /N:$ASSETTAG etc etc
  2. try a piece of software called "wsname.exe" this will rename the machine for you in multiple ways, depending what naming convention you use
  3. Well I miss spelt your name, sorry... i can understand your script... and its wrong lol
  4. Hi I have done the task a different way, not in AutoIT Thanks for help HKISH
  5. Hi This does execute [well the autoIT wrapper does] on the machine but the {printer.exe delete "*" "TREE*"} does not run, if I copy that same command to the run or into a dos box it executes fine
  6. Hi I am trying to create either a RunAS or RunAsWait to run a command line I cope an exe file to the local machine, then run it using the following command line, printer.exe delete "*" "\\TREE\*" I cannot get the syntax to work in AutoIT though, can anyone help? Cheers
  7. Hi all I have sorted this now, thanks for all the help
  8. Thanks..... I have managed to get the new server name to insert, but the example name simply moves to rhe right.. I need my new server name to over write the example, or to delete the example before it writes my new name... Any ideas? Thanks
  9. Hi all This is likely a simple one but I just cant seem to find the answer.. I have written an installer and all works well, but on one input screen I need to insert a server name. I have the server name and need this to be added to the correct input box. how do I script this to be done automaticaly? Thanks
  10. Hi Syed23 Is there a reason 2 arrays need to be used? keith
  11. Thanks forumer100 I have changed it very slightly to $key = "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\" For $i = 1 To 99999 $tempkey = RegEnumKey($key, $i) If @error Then ExitLoop $Displayname = RegRead($key & $tempkey, "DisplayName") $DisplayVersion = RegRead($key & $tempkey, "DisplayVersion") $UninstallString = RegRead($key & $tempkey, "UninstallString") ConsoleWrite($Displayname & @LF & $DisplayVersion & @LF & $UninstallString & @LF & @CRLF & @CRLF) Next however it still does not display keys that use {} only names... the app all ways installs as {this string changes} thanks Keith
  12. Sorry I ment ProductGuid The package leaves registry entries HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CruuentVersion\Unnstall\{this string is different each time} ....i.e no vendor name therefore I need to search within all the entries for SoftwareID or DisplayName & DisplayVersion, then I need the UninstallString from within thanks
  13. Hi thanks for speedy reply, but this will only ready entries with names such as Abobe, Microsoft etc it will not read entries with starting and ending {} thanks Keith
  14. Hi I am trying to write a script that will uninstall a software package. the package generates a different ProductCode on each machine and each time its installed so I cannot use this as a reference. I have been using _RegSearch [with help from PsaltyDS] what I need is a script that would work something like, $www = "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall" $xxx = "DisplayName" $yyy = "DisplayVersion" $zzz = "UninstallString" search on the above then give the UninstallString as an other variable to then allow "Msiexec /X $mmm....etc" to be run thanks
  15. I have now added a second array array 1 gives 2 results array 2 gives 2 results between the 2 I have the 3 required, I just need to merge the 2, or add a section to one, thia is what I have up to now #include <Array.au3> Global $sUninstallKey = "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall" Global $sValName = "UninstallString" Global $sName = "DisplayName" ; Get array of all "UninstallString" values $aUninstallKeys = _RegSearch($sUninstallKey, $sValName, 2, True) ; 2 = Match on Value Names only, True = return array $aUninstallKeys2 = _RegSearch($sUninstallKey, $sName, 2, True) ; 2 = Match on Value Names only, True = return array ; Create 2D array for data Global $aUninstallStrings[UBound($aUninstallKeys)][2] = [[$aUninstallKeys[0], ""]] Global $aUninstallStrings2[UBound($aUninstallKeys2)][3] = [[$aUninstallKeys2[0], ""]] ; Populate 2D array with value location and data For $n = 3 To $aUninstallKeys[0] $aUninstallStrings[$n][0] = $aUninstallKeys[$n] $aUninstallStrings[$n][1] = RegRead(StringTrimRight($aUninstallStrings[$n][0], StringLen($sValName)), $sValName) $aUninstallStrings2[$n][2] = RegRead(StringTrimRight($aUninstallStrings2[$n][0], StringLen($sName)), $sName) Next for $n = 3 To $aUninstallKeys2[0] $aUninstallStrings2[$n][0] = $aUninstallKeys2[$n] $aUninstallStrings2[$n][1] = RegRead(StringTrimRight($aUninstallStrings2[$n][0], StringLen($sName)), $sName) Next ; Display results _ArrayDisplay($aUninstallStrings) _ArrayDisplay($aUninstallStrings2)
×
×
  • Create New...