2
Answers

To track ip address in vb.net

mahesh

mahesh

13y
2.3k
1
Dear All,
           I want to fetch client's ip address as soon as he accesses my web-site built in silverlight application.Then i want to store it in my   database.
Is there any method to achieve this target in silverlight application.
If you could help me i will be very thankful to you.
Answers (2)
0
mahesh

mahesh

NA 116 67.4k 13y
I have referred your links.I have implemented. Code: public class Service1 { [OperationContract] public string DoWork() { OperationContext operationContext = OperationContext.Current; MessageProperties messageProperties = operationContext.IncomingMessageProperties; RemoteEndpointMessageProperty remoteEndpointProperty = messageProperties[RemoteEndpointMessageProperty.Name] as RemoteEndpointMessageProperty; return string.Format("Your IP address is {0} and your port is {1}", remoteEndpointProperty.Address, remoteEndpointProperty.Port); }  }
i hosted virtually ex:192.168.1.11/ip ,when i access with other system,it's giving that system ip.But when i host ex:122.166.48.230/ip,when i access with other system,it's giving our static network ip but it's not giving that system ip.Can you please help me. Thanks in advance.
0
Suthish Nair

Suthish Nair

NA 31.7k 4.6m 13y