Reputation: 394
I am trying to find a way to programmatically get the network statistics for a specific adapter in Windows 10. I found that GetIpStatistics() function, but it returns statistics for all adapters. Does anyone know of a function that gets the same type of statistics but only for a specific adapter?
Upvotes: 1
Views: 423
Reputation: 595339
You can use GetIfTable()
or GetIfTable2()
, and then look for the desired interface in the returned table.
Or, if you already know the LUID/index of the desired interface, you can use GetIfEntry2()
or GetIfEntry2Ex()
instead.
Upvotes: 2