मैं एक कस्टम प्रदर्शन काउंटर बनाया है निम्नलिखित कोड का उपयोग कर पुनर्स्थापित करने के लिए कैसे:कस्टम प्रदर्शन काउंटर
public class PerfCounter
{
private PerformanceCounter perfCounter;
PerfCounter(string CategoryName, string CounterName)
{
perfCounter = new PerformanceCounter(CategoryName, CounterName, false);
perfCounter.BeginInit();
}
public void IncrementBy(long value)
{
perfCounter.IncrementBy(value);
}
public void Reset()
{
//what should I add here?
}
}
सब कुछ ठीक काम करता है, लेकिन मैं काउंटर रीसेट करने के लिए कैसे पता नहीं है। क्या कोई मेरी मदद कर सकता है?
शायद यह मदद मिलेगी? http://stackoverflow.com/questions/9195851/reset-performance-counter-from-command-line – Freddy