I'm writing a batch script to update a software package (uninstall old version/ install new one). This needs to be done over the network as there are 500 PCs to update. One of the first steps before uninstalling is checking wether that software is installed or not. In order to check that I query the registry:
reg query "HKLM\SOFTWARE\A.E.T Europe B.V."
This query gives adecuate results when running in local (for testing purposes), but when I run it remotely (they way it will be ran) returns wrong results.
reg query "\\I301\HKLM\SOFTWARE\A.E.T Europe B.V."
returns 0 if i run that line locally. But if I log into I301 and run the query locally returns 1, being the truth that A.E.T Europe B.V. shows up under the Wow6432Node branch in the windows registry.
Why is that???
Thanks in advance!