本文整理自网络,侵删。
Unigui获取连接的客户端列表
var I : Integer; ASessionList: TList; ASession : TUniGUISession;begin memo1.Clear; ASessionList:=UniServerModule.SessionManager.Sessions.SessionList.LockList; try for I := 0 to ASessionList.Count-1 do begin ASession := TUniGUISession(ASessionList[I]); if not ASession.IsTerminated then memo1.Lines.Add( ASession.UniApplication.RemoteAddress ); end; finally UniServerModule.SessionManager.Sessions.SessionList.UnlockList; end;
https://blog.csdn.net/shuiying/article/details/8967738
相关阅读 >>
Delphi tms web core 通过url 传递参数
Delphi 如何确定access数据库中存在某一个已知名的表
Delphi char数组、string和pchar的相互转换
更多相关阅读请进入《Delphi》频道 >>