System Variables › &ZMAIACT# or &ZMAIACTN
Returns the number of active sessions associated with the current window.