+ Reply to Thread
Results 1 to 3 of 3

VBA Read the MAC address of a computer ? (Mac OSX Excel 2011)

  1. #1
    Registered User
    Join Date
    07-11-2012
    Location
    Gethen Sullivan
    MS-Off Ver
    Excel 2011 Mac OS
    Posts
    2

    VBA Read the MAC address of a computer ? (Mac OSX Excel 2011)

    Hi,

    I have a spreadsheet which I'm incorporating MAC checking as a security feature to prevent the spreadsheet being used on different computers.

    I found some code online which works fine on Windows.
    ------
    Please Login or Register  to view this content.
    ------

    I'm new to Mac OSX, but the code which works in a terminal window to display the MAC address is;
    ----
    networksetup -listallhardwareports | egrep -A 2 "(AirPort|Wi-Fi)" | grep Ethernet
    ----

    I'm just not sure how to covert the first section of code so that it works on a Mac.
    Hopefully this can be done without having to call a separate script file.

    Any tips, would be greatly appreciated.

    Thank you
    Last edited by arlu1201; 07-11-2012 at 09:16 AM. Reason: Use code tags in future.

  2. #2
    Forum Guru JosephP's Avatar
    Join Date
    03-27-2012
    Location
    Ut
    MS-Off Ver
    2003/10
    Posts
    7,328

    Re: VBA Read the MAC address of a computer ? (Mac OSX Excel 2011)

    the first one will never work on a mac because wmi is the Windows Management Interface. but you can use the shell script you have using
    Please Login or Register  to view this content.
    Josie

    if at first you don't succeed try doing it the way your wife told you to

  3. #3
    Registered User
    Join Date
    07-11-2012
    Location
    Gethen Sullivan
    MS-Off Ver
    Excel 2011 Mac OS
    Posts
    2

    Re: VBA Read the MAC address of a computer ? (Mac OSX Excel 2011)

    Thanks mate, you're a legend!

    Works perfectly.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1