Skip to Content

Imagine you have developed your own dashboard and there are hundreds of people across the globe visiting your dashboard every day. Do you want to restrict or show data depending upon visitor’s country? In this article I will use a Web Service from www.webservicex.net and Xcelsius Web Service connection to find the country from the IP addresses.

Here are the detailed steps:

  1. Launch Xcelsius/Dashboard Design, go to Data Manager and add Web Service Connection:

/wp-content/uploads/2013/05/1_219281.jpg

 

   2. Now we will use following WSDL URL from www.webservicex.net and find country from IP Address:

       http://www.webservicex.net/geoipservice.asmx?WSDL

       Note: We can use any other Web Service which provides country name from IP Address. We can even build our own Web Service for                this. I am using Web Service from www.webservicex.net as an example in this article.

   3. Paste above URL in front of WSDL URL under Data Manager and click on Import:

/wp-content/uploads/2013/05/3_219282.jpg

   4. Notice that Input Values and Output Values panes are populated with following fields:

    • Input Values Pane:

            IPAddress: This is the Web Service parameter. We are going to pass IP Address to a Web Service using this field.

    • Output Values Pane:

ReturnCode: Returns 1 for valid IP Address else returns 0

IP: Returns IP Address passed to the Web Service

ReturnCodeDetails: Returns Success if passed IP Address is valid else returns Invalid IP Address

Country Name: Returns the name of the country  corresponding the passed IP Address

Country Code: Returns country  for the detected country for example for India country , country  code returned will be IND

/wp-content/uploads/2013/05/4_219283.jpg

   5. Map required fields from Input Values and Output Values pane with excel spreadsheet:

/wp-content/uploads/2013/05/5_219293.jpg

   6. Now we can pass IP Address to the IPAddress Web Service parameter using let’s say Input Text component and display country name       in a Label component.


   7. Enter IP Address in a Input Text component and click on Refresh button:

/wp-content/uploads/2013/05/7_1_219294.jpg

/wp-content/uploads/2013/05/7_2_219295.jpg

/wp-content/uploads/2013/05/7_3_219377.jpg

You will see the country corresponding to the entered IP Address in the Results pane.

   8. Alternatively you can select IP Address from the Scorecard and see the corresponding country name:

/wp-content/uploads/2013/05/7_4_219378.jpg

I have displayed country map using dynamic visibility on the right side of the dashboard. I have taken four countries (India,Japan,Malaysia,Thailand) as an example.

I have attached ‘IP Address Location.txt’ file with this article. Download and rename it to ‘IP Address Location.xlf’



To report this post you need to login first.

4 Comments

You must be Logged on to comment or reply to a post.

        1. Vinaykumar Mhaske Post author

          Hi Avinash,

          I did not find any Web Service on internet which returns the IP Address. 🙁

          I think the only way to achieve this is to write a Web Service (using Dot Net, Php, Java etc..) and create a dashboard using Web Service connection.

          Regards,

          Vinay Mhaske

          (0) 

Leave a Reply