So I wrote a script on Windows XP that connects to remote computers with administrative credentials, performs a number of tasks and outputs values to a .csv file. On Windows XP it ran smoothly, but when I ran the same script on a Windows 7 machine, I got path not found errors, and the output file didn't have anything. So I was wondering if the specifications for a wbemServices server connection is different in Win7.

Here is a snippet of the code I'm using to connect to remote computers:
Set objSWbemLocator = CreateObject("WbemScripting.SWbemLocator")
Set objSWbemServices = objSWbemLocator.ConnectServer _
(ComputerName, "root\cimv2", "domain\username", "password")
objSWbemServices.Security_.ImpersonationLevel = 3

Any help would be extremely appreciated.

Thanks