View previous topic :: View next topic |
Author |
Message |
louis
Joined: 19 Oct 2005 Posts: 9
|
Posted: Wed Jan 10, 2007 5:38 pm Post subject: Getting the hardware MAC address and IP address from Fortran |
|
|
Is there a way of getting the hardware (eg ethernet card_ MAC address
and IP address from within a Fortran program without calling ipconfig ?
I can do it via
call system('ipconfig /all >ip.txt')
but this flashes up a DOS box because of the call to ipconfig.
I would like to use a Win API call to get this in a completely "silent" way |
|
Back to top |
|
|
Andrew
Joined: 09 Sep 2004 Posts: 232 Location: Frankfurt, Germany
|
Posted: Thu Jan 11, 2007 2:18 pm Post subject: |
|
|
The way to do this via the Win32 API is to use GetAdaptersInfo. You may find it easier (maybe even neccessary) to use C for the task. Info about the routine can be found at:
http://msdn2.microsoft.com/en-us/library/aa366062.aspx |
|
Back to top |
|
|
|