BTA Flexing

My passion RIAs…………..Shardul Singh Bartwal

Getting Ethernet Adapter(MAC Address in AIR Applicaion)

Posted by Shardul Singh Bartwal on October 3, 2010

Its very simple and easy to get the MAC address of any computer with Adobe AIR application.

With just two to three lines you can find it very easily.Just have a look at lines below
and you will get the MAC address of the computer in which your application is running.

var networkInterface : Object =  NetworkInfo.networkInfo.findInterfaces();
var networkInfo  : Object = networkInterface[0];
var physicalAddress : String = networkInfo.hardwareAddress.toString();

Hope you will like it…………

Enjoy Flexing…….


7 Responses to “Getting Ethernet Adapter(MAC Address in AIR Applicaion)”

  1. thunder said

    nice thanks,
    btw it is spelled ethernet not eathernet 🙂

  2. shardulbartwal said

    Thnx man,

  3. AlphaBlack said

    can you put an example please.i’m new in flex and adobe air and i want to understand how these works. thanks

  4. Thanks for the brief intro. I also found this article that is more detailed:

  5. Josh said

    You will get the address of the first interface that is found. It probably won’t be for the Ethernet adapter.

    See the link posted by Bradley White above

  6. vkwave said

    Perfect. Thanks for sharing

  7. Prashant. said


    On windows machine It works perfectly, but on MAC OS (Version 10.6.2) I am getting empty string.
    Please can anyone help me to get MAC address on windows as well as MAC os.

    Thanks in advanced.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: