The MAC address belongs to the network card not the computer so many will have more than one

You can use this command prompt command to get a CSV of the info and then read it in

GETMAC /fo csv /v > somefile.txt

There is a WinAPI command GetAdapterInfo but that is a bit more involved to call although someone like Sture or Wil may have already done it