views:

250

answers:

1

how to know the P address of the system in which the AIR application is currently running? or

how to restrict the usage of AIR application for a particular country?

A: 

Please try the following code, it works for me.

import flash.net.InterfaceAddress;

import flash.net.NetworkInterface;

var netInterfaces:Vector. = NetworkInfo.networkInfo.findInterfaces();

var addresses:Vector. = netInterfaces[0].addresses;

ipAddress = addresses[0].address;