Dundas Chart for Windows Forms
GetGradientColor Method
See Also  Send comments on this topic.
DundasWinChart Assembly > Dundas.Charting.WinControl Namespace > ChartGraphics Class : GetGradientColor Method


beginColor
The color from the gradient beginning.
The color from the gradient begining.
endColor
The color from the gradient end.
The color from the gradient end.
dPosition
Relative position between the beginning color and end colors. Ranges from 0 - 1.
Relative position between Begin color and End color. The double number between 0 - 1.
Returns the gradient color from a given gradient position.
Returns the gradient color from a gradient position.

Syntax

Visual Basic (Declaration)  
Public Shared Function GetGradientColor( _
   ByVal beginColor As Color, _
   ByVal endColor As Color, _
   ByVal dPosition As Double _
) As Color
Visual Basic (Usage) Copy Code
Dim beginColor As Color
Dim endColor As Color
Dim dPosition As Double
Dim value As Color
 
value = ChartGraphics.GetGradientColor(beginColor, endColor, dPosition)
C#  
public static Color GetGradientColor( 
   Color beginColor,
   Color endColor,
   double dPosition
)

Parameters

beginColor
The color from the gradient beginning.
The color from the gradient begining.
endColor
The color from the gradient end.
The color from the gradient end.
dPosition
Relative position between the beginning color and end colors. Ranges from 0 - 1.
Relative position between Begin color and End color. The double number between 0 - 1.

Return Value

Result color.

Requirements

Target Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family, Windows Vista, Windows Server 2008 family

See Also

© 2009 All Rights Reserved.