I made some minor changes to your script.
Please give it a once over and see if it is clear what it does and if it works better for you.

 Code:
If Left(@IPADDRESS0, 8) = " 10. 20."
	MD "c:\Proxy_" + @USERID
	Copy "\\mydomain\netlogon\file.pac" "c:\Proxy_" + @USERID + "\file.pac"
	$key = "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Internet Settings"
	$rc = WriteValue($key, "AutoConfigURL", "file://c:/proxy_" + @USERID + "/file.pac", "REG_SZ")
	$rc = WriteValue($key, "ProxyEnable", "0", "REG_DWORD")
	$rc = WriteValue("HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced", "Hidden", "2", "REG_DWORD")
EndIf
_________________________
Mart

- Chuck Norris once sold ebay to ebay on ebay.