Getting parameters from IdHTTPServer – Firemonkey


I’m trying to get Dropbox token from call-back parameters but the parameters are always empty.

Here is my code:

sURL :=’ +
‘?response_type=token’ +
‘&client_id=’ + MyAppID +

ShellExecute(0, ‘OPEN’, PChar(sURL), ”, ”, SW_SHOWNORMAL);

Next I have IdHTTPServer set to listen address.

On executing the browser with Dropbox log-in popup. When I made log-in the redirection is made and the “IdHTTPServerCommandGet” events is called. So far so good.

In the browser I can see the next URL:

But in “IdHTTPServerCommandGet” events the parameters are always empty:

ARequestInfo.UnparsedParams; // Empty

ARequestInfo. QueryParams; // Empty

if ARequestInfo.Params.Count > 0 then // Empty
sToken := ARequestInfo.Params[0];

And here is my question. How can I get the whole URL with parameters from IdHTTPServer?

Comments are closed.