![]() |
IDHTTPServer und Rückgabewert
Hallo,
ich habe eine Kombination zweier Programme, welche über das HTTP Protokoll kommunizieren sollen (z.B. Statusabfrage). Im "client" habe ich folgenden Code platziert
Delphi-Quellcode:
Im Serverteil des anderen Programmes habe ich folgendes:
lStream := TStringStream.Create('');
try lResultStr := IDHTTP.Post('http://192.168.1.5/status', lStream); finally lStream.Free; end;
Delphi-Quellcode:
Ich würde nun gerne im Client, den Rückgabewert auswerten können, aber das kommt einfach nicht an. Vermutlich verwende ich einfach eine falsche Eigenschaft.
procedure TForm1.HTTPSRVCommandGet(AThread: TIdPeerThread;
ARequestInfo: TIdHTTPRequestInfo; AResponseInfo: TIdHTTPResponseInfo); begin if (UpperCase(ARequestInfo.Document) = '/STATUS') then aResponseInfo.ContentText := '1'; end; Hat vielleicht jemand einen Hinweis was ich falsch mache? |
Alle Zeitangaben in WEZ +1. Es ist jetzt 16:07 Uhr. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024-2025 by Thomas Breitkreuz