You are developing a method named CreateCounters that will create performance counters
for an application. The method includes the following code. (Line numbers are included for
reference only.)
You need to ensure that Counter2 is available for use in Windows Performance Monitor
(PerfMon).
Which code segment should you insert at line 16?

A.
CounterType = PerformanccCounterType.RawBase
B.
CounterType = PerformanceCounterType.AverageBase
C.
CounterType = PerformanceCounterType.SampleBase
D.
CounterType = PerformanceCounterType.CounterMultiBase
B. CounterType = PerformanceCounterType.AverageBase;
Right answer is B.
1
0
C
0
1
Right answer is B.
0
0
Correct answer:
B.
CounterType = PerformanceCounterType.AverageBase
0
0
B
0
0
Can anyone explain why the answer is B ?
0
0
some counters requires to be followed by base counters and some are not.
AverageTimer requires to be followed by AverageBase counter
… and CounterMultiTimer (and some other) requires to be followed by CounterMultiBase
Since we have AverageTimer here, it must be followed by AverageBase
4
0
Correct B
For more information see this link: https://msdn.microsoft.com/en-us/library/system.diagnostics.performancecountertype%28v=vs.110%29.aspx
1
0
Actually B is the right answer,
AverageBase
A base counter that is used in the calculation of time or count averages, such as AverageTimer32 and AverageCount64. Stores the denominator for calculating a counter to present “time per operation” or “count per operation”.
and about c u cant use SampleBase width AverageTimer32 ,
to use SampleBase u need SampleFraction
RawBase RawFraction
https://msdn.microsoft.com/en-us/library/system.diagnostics.performancecountertype(v=vs.110).aspx
1
0
C is the right answer !
0
1
B
0
2