Hi and welcome to this board.

This should do the job for you. Of course it should be altered to really add the printers but you can see exactly in what section the system ends up.

Code:

;Get the third octet of the ip address.
$ip = SubStr(@IPADDRESS0, 9, 3)
;
;Remove spaces.
$ip = Trim($ip)

;Do stuff based on third octet.
Select
Case $ip = "34"
?"PC is in 34 subnet."
?"Add printers from 34 subnet."
Case $ip = "35"
?"PC is in 35 subnet."
?"Add printers from 35 subnet."
Case $ip = "36"
?"PC is in 36 subnet."
?"Add printers from 36 subnet."
Case $ip = "37"
?"PC is in 37 subnet."
?"Add printers from 37 subnet."
EndSelect



Edited by Mart (2006-03-28 11:26 AM)