How can I determine the IP address from which data is come from a TCP Inbound Adapter?

Primary tabs


We want to be able to dispatch based on the IP address who connected to a TCP Inbound adapter.  

The address is in ..Adapter.%outIPAddr when the connection is made and reported with $$$LOGINFIO() but by the time OnProcessInput() is called the value is blank.  


Hi Kevin,

You can use IOAddr property from EnsLib.TCP.CountedInboundAdapter

IOAddr property come in this format : 57777<-

To extract the source IP adresse you can parse it like that :

set fullIOAddr = ..Adapter.IOAddr //57777<-
set remoteIP = $P($P(fullIOAddr,"-",2),":",1) //