The UserDomainName property first attempts to get the domain name component of the Windows NT 4.0 account name for the current user. The account name is formatted as domain name, the '\' character, and user name. If that attempt fails, this property attempts to get the domain name associated with the user name provided by the UserName property. If that attempt fails because the host computer is not joined to a domain, then the host computer name is returned.
Windows 95, Windows 98, Windows 98 Second Edition, Windows Millennium Edition Platform Note:
The UserDomainName property is not supported for this platform.