I'm trying to display the received bytes per second and have them displayed in the console once a second. The I am presented with a Invalid Operation Exception once it reaches .nextvalue.
PerformanceCounter NetworkDownSpeed = new PerformanceCounter("Network Interface", "Bytes Received/sec");
float CurrentNetworkDownSpeed = (int)NetworkDownSpeed.NextValue();
while (true)
{
Console.WriteLine("Current Network Download Speed: {0}MB", CurrentNetworkDownSpeed);
Thread.Sleep(1000);
}