<div class="content" name="WINSTATIONSTATECLASS" uuid="b619d8aa-4e8a-4716-954e-a4d596ed37f8"><p>The WINSTATIONSTATECLASS enumeration represents the current
state of a session.</p><dl>
<dd>
<div><pre> typedef  enum _WINSTATIONSTATECLASS
 {
   State_Active = 0,
   State_Connected = 1,
   State_ConnectQuery = 2,
   State_Shadow = 3,
   State_Disconnected = 4,
   State_Idle = 5,
   State_Listen = 6,
   State_Reset = 7,
   State_Down = 8,
   State_Init = 9
 } WINSTATIONSTATECLASS;
</pre></div>
</dd></dl><p><b>State_Active:  </b>A user is logged on to a
session and the client is connected.</p><p><b>State_Connected:  </b>A client is connected to a
session but the user has not yet logged on.</p><p><b>State_ConnectQuery:  </b>A session is in the
process of connecting to a client.</p><p><b>State_Shadow:  </b>A session is shadowing another
session.</p><p><b>State_Disconnected:  </b>A user is logged on to
the session but the client is currently disconnected from the server.</p><p><b>State_Idle:  </b>A session is waiting for a client
to connect to the server.</p><p><b>State_Listen:  </b>A <span><a href="c41d3367-04c9-4c93-babf-9b5de834eb29#gt_1e5aa0c2-4617-4d7a-969e-a7091c415c8d" data-linktype="relative-path">listener</a></span> is waiting
for connections from the Terminal Services client.</p><p><b>State_Reset:  </b>A session is being reset. As a
result, the user is logged off, the session is terminated, and the client is
disconnected.<a id="Appendix_A_Target_37"></a><a aria-label="Product behavior note 37" href="7ce7f717-461b-4f18-9829-6690168c7707#Appendix_A_37" data-linktype="relative-path">&lt;37&gt;</a></p><p><b>State_Down:  </b>A session is currently tearing
down or is in the down state, indicating an error.</p><p><b>State_Init:  </b>A session is in the process of
being initialized.</p></div>