You'd be much better served using an external table of subnets/office names/ data (tab delimited) and employ one of the IsInSubnet UDF variants. Hard coding data into a script makes it less portable and prone to errors when you need to modify/update it.
Look at the GetNetInfo UDF on my web site - it will do exactly what you need. Create a simple table of subnets, site names, and other data, delimited with tabs. When you feed the UDF an IP address, it will determine which subnet it is in and return a field from the corresponding record. There are defaults for field # and file location, but you can specify them in the UDF arguments.
Use the Shell command to kick off the regedit command.
If you are using Kix 4.60, you need to specify "Kix32.exe kixtart.kix" in your user profile. There's a bug in 4.60 that prevents it from locating the default startup script.
Glenn
_________________________
Actually I
am a Rocket Scientist!