Atozed Forums

Full Version: Number of remaining sessions if I close one session
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hallo,

I have an IntraWeb SA application. If the user closes a session I want to get the count of the remaining sessions.
I call "gSessions.getCount" in TIWServerController.IWServerControllerBaseCloseSession method.
Then my application hangs.

Code:
procedure TIWServerController.IWServerControllerBaseCloseSession(aSession: TIWApplication);
var
 nCount : integer;

begin
 try
   nCount := gSessions.getCount;
 except
 end;
end;


How could I get the number of the remaining sessions at this point?

Best regards
Sessions are locked and have critical sections at various points. Without digging into code, I would bet its locked during this event and you should try a different event.