TX Text Control .NET for WPF

ChartEventArgs Class

Class|Introduced in 18.0
Namespace
TXTextControl.DataVisualization
Package
TXTextControl.TextControl.WPF.SDK from the private NuGet feed or Text Control Offline Packages
Assembly
TXTextControl.dll
Install
dotnet add package TXTextControl.TextControl.WPF.SDK .NET 8 and later. For .NET Framework, reference TXTextControl.dll from the setup.
Inherits
  1. EventArgs
  2. ChartEventArgs

Description

The ChartEventArgs class provides data for all events that occur with charts. These are the TextControl.ChartCreated, TextControl.ChartDeleted, TextControl.ChartClicked, TextControl.ChartDoubleClicked, TextControl.ChartRightClicked, TextControl.ChartMoved TextControl.ChartSelected, TextControl.ChartDeselected and TextControl.ChartSized events.

Syntax

public class ChartEventArgs : EventArgs

Examples

The following example uses ChartEventArgs.ChartFrame while handling ChartClicked.

textControl.ChartClicked += (_, e) =>
{
    if (e.ChartFrame != null)
    {
        e.ChartFrame.DescriptiveText = "Quarterly sales by region";
    }
};

Members

Properties

PropertyDescription
ChartFrameGets an object that represents the chart which causes the event. It is of the type DataVisualization.ChartFrame.