Board index » delphi » INDY HTTP - Binding addr:port

INDY HTTP - Binding addr:port

Can someone please give me the correct sytax to bind multiple
IP_address:PORT 's to the HTTP (or any i suppose) INDY server component.

I cant see what to do after:

    IdHTTPServer1.Bindings.DefaultPort:=globalconfig.port;
    IdHTTPServer1.Bindings.Items.XXXXX

Thanks

 

Re:INDY HTTP - Binding addr:port


"Matt Saint" <m...@e-shop.uk.comSPAM> schrieb im Newsbeitrag
news:3bfa3f46_1@dnews...

Quote
> Can someone please give me the correct sytax to bind multiple
> IP_address:PORT 's to the HTTP (or any i suppose) INDY server component.

> I cant see what to do after:

>     IdHTTPServer1.Bindings.DefaultPort:=globalconfig.port;
>     IdHTTPServer1.Bindings.Items.XXXXX

----------------------
procedure TFm_Main.RestartServer(Start: boolean);
var
  ip_string: string;
begin
  if V61STCPServer.Active then V61STCPServer.Active := false;
  V61STCPServer.Bindings.Clear;
  if V61RTCPServer.Active then V61RTCPServer.Active := false;
  V61RTCPServer.Bindings.Clear;
  LbStatusServer.Caption := ServerString[0];
  if not Start then Exit;
  { ------------------- }
  try
    ip_string := '';
    case IPListArt of
      1 : ip_string := Trim(FesteIP);
      2 : ip_string := Trim(CBoxLAdressen.Items[IPListNum]);
    end;
    V61STCPServer.DefaultPort := PortNr;
    V61RTCPServer.DefaultPort := PortNr + 1;
    with V61STCPServer.Bindings.Add do begin
      Port := PortNr;
      IP   := ip_string;
    end;
    with V61RTCPServer.Bindings.Add do begin
      Port := PortNr + 1;
      IP   := ip_string;
    end;
    V61STCPServer.Active := true;
    V61RTCPServer.Active := true;
    LbStatusServer.Caption := ServerString[1];
  except
    LbStatusServer.Caption := ServerString[2];
  end;
end;
----------------------
hth Ernst

Other Threads