Where not running ADSI, this is an NT4 domain.

The above example does not address my statement, "Depending on which range of the name falls in I need to copy a particular hosts. file to the PC."

I need to read the workstation name and determine if it falls into a predetermined range of names, then assign the appropriate hosts. file for that range.

Example:

If $wksta is xxxxxe220 – xxxxxe250 copy hosts1. to $path\hosts.
If $wksta is xxxxxw100 – xxxxxw150 copy hosts2. to $path\hosts.
If $wksta is xxxxxm1 – xxxxxm60 copoy hosts3 to $path\hosts.

Note: All users have admin rights to the workstation during login.

Thanks,
_________________________
Dave Melbourne, FL