PerformanceCounter

The PerformanceCounter component provides an instance of a Windows NT performance counter. The component can be used for reading predefined or custom counters and publishing (writing) performance data to custom counters. Performance that can be data collected includes busy time for a processor, memory usage, or the size of data (in bytes) received over a network.

The registry stores the names of all available counters, each of which is related to a specific area of system functionality. For the component, the counter information must include the category for which the counter measures data. The categories for a computer relate to a functional element within the computer and include hardware like disks and memory, and system categories such as processes. A set of standard counters is assigned to each available category.

Properties

The key properties for the PerformanceCounter component include:

  • CounterHelp. Specifies the description for this performance counter.

  • CounterType.Specifies the counter type of the associated performance counter.

  • InstanceLifetime. Determines whether the lifetime of the process is Global or for the Process.

    Note: If the value of the CounterType property is SingleInstance, the InstanceLifetime value for the performance counter must be Global.

Adding a PerformanceCounter

When you drag a PerformanceCounter component from the Toolbox to a form in Flow Designer, it will appear as an entry in the design space.

You can select the control and configure it using the Properties pane.

More information on the PerformanceCounter component can be viewed at the link to Microsoft® Documentation.