Here's the code...

;Map HP12whse Printer
$SystemList= 'terminalserver','dbserver3','printserver','mainfileserver','SBCS'
AScan ($SystemList, @WKSTA) = -1
IF INGROUP("HP12WHSE")
If AddPrinterConnection ("\\printserver\HP12WHSE") = 0
? "Attach network printer \\printserver\HP12WHSE"
Endif
endif

The code would not accept another endif at the end.