I am porting an app from net 1.1 to .net 2.0. I have a line of code
(which sets up Performance Counters) that the new framework has obsoleted:
CounterCreationDataCollection CCDC = new CounterCreationDataCollection();
// obsoleted line
PerformanceCounterCategory pcc = PerformanceCounterCategory.Create("My
Category", "My Category Description", CCDC);
The preferred line is now:
pcc = PerformanceCounterCategory.Create("My Category", "My Category
Description",
PerformanceCounterCategoryType.SingleInstance, CCDC);
The difference obviously is the PerformanceCounterCategoryType enum
which supports SingleInstance and MultiInstance. From the sparse
documentation, I am not quite grokking the difference between the 2. I
want my code to work as it did under 1.1 framework. Which enumeration
value should I use?
Thanks.