Here's how:
[lang='vb']Dim objNetwork, strPrintServer
Set objNetwork = WScript.CreateObject("WScript.Network")
strPrintServer = "\\Your_Print_Server"
Private function GetUserObject
On Error Resume Next
Set GetUserObject = GetObject("WinNT://" objNetwork.UserDomain "/" objNetwork.UserName)
End function
set UserObject = GetUserObject
For Each Group in UserObject.Groups
Select case Group.Name
Case "Your_AD_Security_Group"
objNetwork.AddWindowsPrinterConnection strPrintServer "\Your_Printer_Name"
End Select
Next[/lang]
To set the default printer:
[lang='vb'] Select case Group.Name
Case "Your_AD_Security_Group DEFAULT"
objNetwork.setDefaultPrinter strPrintServer "\Your_Printer_Name"[/lang]
Job done.

