Ver Mensaje Individual
  #1  
Antiguo 12-05-2008
SMTZ SMTZ is offline
Miembro
 
Registrado: nov 2003
Posts: 225
Reputación: 21
SMTZ Va por buen camino
Post Escuchar por IP y puerto

Hola, estoy intentando hacer que una aplicación escuche por una IP y un puerto en concreto mediante el siguiente código:


Código:
Var
   Canal        : TCPServerChannel;
   Propiedades  : Hashtable;
Begin

   ConfiguracionRed;

   //***********

   Propiedades := Hashtable.Create;
   Propiedades['Name'] := 'AppServeredav';
   Propiedades['bindTo'] := IP;
   Propiedades['Port'] := Puerto.ToString;
   Propiedades['RejectRemoteRequests'] := 'false';
   Propiedades['typeFilterLevel'] := 'Full';
   Propiedades['useIpAddress'] := 'True';

   Canal := TCPServerChannel.Create( Propiedades, nil );
   Canal.StartListening( nil );

   ChannelServices.RegisterChannel( Canal, False );

   Propiedades.Free;

Tras buscar y buscar soluciones, este código compila y se ejecuta perfectamente pero la aplicación no escucha, sin ambargo, si utilizo un código más sencillo, no tengo problemas (el telnet puerto funciona) pero no puedo elegir la IP de eschucha:

Código:
Canal := TCPServerChannel.Create( Puerto );
ChannelServices.RegisterChannel( Canal, true );

¿Alguien sabe por qué no escucha la aplicación "forzando" la IP?


Gracias.
Responder Con Cita