Version

Change Icons in a Scatter Chart

This topic will explain how to change the icons displayed in a scatter chart. The chart contains seven built-in icons that can be displayed. They are Plus, X, Triangle, Square, Circle, Diamond, and Upside Down Triangle. You determine which one will be displayed by setting the Icon property.

  1. Before you start writing any code, you should place using/import directives in your code-behind so you don’t need to always type out a member’s fully qualified name.

In Visual Basic:

Imports Infragistics.UltraChart.Shared.Styles

In C#:

using Infragistics.UltraChart.Shared.Styles;
  1. To change the icon used in the Scatter chart to a diamond, enter the following code:

In Visual Basic:

Me.UltraChart1.ScatterChart.Icon = SymbolIcon.Diamond

In C#:

this.ultraChart1.ScatterChart.Icon = SymbolIcon.Diamond;
  1. In addition to the built-in icons, a custom character can also be displayed. The Icon property will need to be set to 'Character' and then the Character property should be set to the character that will be displayed in the chart. This can be a letter, a number or any other symbol on the keyboard.

In Visual Basic:

Me.UltraChart1.ScatterChart.Icon = SymbolIcon.Character
Me.UltraChart1.ScatterChart.Character = "@"

In C#:

this.ultraChart1.ScatterChart.Icon = SymbolIcon.Character;
this.ultraChart1.ScatterChart.Character = '@';