2.2.2.6.1.2 EXECENVDATA_LEVEL2

The EXECENVDATA_LEVEL2 structure contains information about sessions running on a computer that is more detailed than the information contained in EXECENVDATA_LEVEL1.

 typedef struct _EXECENVDATA_LEVEL2 {
   LONG ExecEnvId;
   LONG State;
   WCHAR SessionName[33];
   LONG AbsSessionId;
   WCHAR HostName[33];
   WCHAR UserName[33];
   WCHAR DomainName[33];
   WCHAR FarmName[33];
 } EXECENVDATA_LEVEL2,
  *PEXECENVDATA_LEVEL2;

ExecEnvId: An identifier assigned to the session contained in this structure by the component that aggregates the sessions on the server and sessions within virtual machines hosted on the server.<53>

State: The state of the session, as specified in section 3.3.4.1.8.

SessionName: A string that contains the name of the session followed by the terminating NULL character.

AbsSessionId: An identifier assigned by the operating system running in the virtual machine to the session contained in this structure. If the session contained in this structure is not running under the virtual machine, the value of AbsSessionId is same as ExecEnvId.

HostName: A string that contains the name of the machine that hosts the session contained in this structure followed by the terminating NULL character.

UserName: A string that contains the name of the user logged onto the session followed by the terminating NULL character.

DomainName: A string that contains the domain of the user logged onto the session followed by the terminating NULL character.

FarmName: A string that contains the farm name associated with the session followed by the terminating NULL character.