I use
 Code:
; Con=Direct Console, RDP=Terminal Server, or ICA=Citrix
$ConnType = Left(%SESSIONNAME%, 3)
, so if the result is "CON", you're NOT on a RDS/Citrix host.

Glenn

PS - use CODE tags!! \:\)
_________________________
Actually I am a Rocket Scientist! \:D