$ 0 0 When UserDomain is NULL, does ConnectedDomain match the domain specified by System.Environment.UserDomain? I may have a logic error if you are getting UserName but not UserDomain.