ARequestInfo.Session is nil (D2007-Indy 10)

Giganews Newsgroups
Subject: ARequestInfo.Session is nil (D2007-Indy 10)
Posted by:  Felipe Colinas (felipecolinas…@yahoo.com.ar)
Date: Mon, 27 Dec 2010

Hi All,

I try to use ARequestInfo.Session.Content, but I ARequestInfo.Session is
always nil. I define the server in this way:

  object HTTP: TIdHTTPServer
    Bindings = <>
    AutoStartSession = True
    KeepAlive = True
    SessionState = True
    OnCommandGet = HTTPCommandGet
end

Also, my OnCommandGet is:

procedure TSVRMain.HTTPCommandGet(AContext: TIdContext;
  ARequestInfo: TIdHTTPRequestInfo; AResponseInfo: TIdHTTPResponseInfo);
begin
  if Assigned(ARequestInfo.Session) then ...
end;

What do I have to do for using it?

Thank you.

Felipe.

Replies