Imports Infragistics.UltraGauge.Resources
Applying the Image Fill brush element to a property of your gauge renders the property as an image.
To apply the Image Fill brush element to a property of your gauge at design time:
Before you start writing any code, you should place using/Imports 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.UltraGauge.Resources
In C#:
using Infragistics.UltraGauge.Resources;
Create the load event, and add the following code.
Create instances of the classes:
In Visual Basic:
Dim myRadialGauge As RadialGauge = Me.UltraGauge1.Gauges(0) Dim imageBrushElement1 As New ImageBrushElement()
In C#:
RadialGauge myRadialGauge = this.ultraGauge1.Gauges[0] as RadialGauge; ImageBrushElement myImageBrushElement = new ImageBrushElement();
Apply the image fill brush element to the Dial property.
In Visual Basic:
imageBrushElement1.Image = Image.FromFile("infragisitics_LOGO_140.gif") imageBrushElement1.ImageFit = Infragistics.UltraGauge.Resources.ImageFit.Tile myRadialGauge.Dial.BrushElement = imageBrushElement1
In C#:
myImageBrushElement.Image = Image.FromFile("infragisitics_LOGO_140.gif"); myImageBrushElement.ImageFit = Infragistics.UltraGauge.Resources.ImageFit.Tile; myRadialGauge.Dial.BrushElement = myImageBrushElement;