バージョン

ResolveButtonAppearance メソッド (UltraScrollBar)

ボタンのプロパティを解決します。
シンタックス
'宣言
 
Public Sub ResolveButtonAppearance( _
   ByRef appearance As AppearanceData, _
   ByRef requestedProps As AppearancePropFlags _
) 
public void ResolveButtonAppearance( 
   ref AppearanceData appearance,
   ref AppearancePropFlags requestedProps
)

パラメータ

appearance
更新された外観情報を格納する構造体。
requestedProps
解決するプロパティを示すフラグ列挙体。
使用例
Imports Infragistics.Win
Imports Infragistics.Win.UltraWinScrollBar

Private Sub button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles button1.Click

    Dim appData As AppearanceData
    Dim requestedProps As AppearancePropFlags

    ' -------------------------------------------------------
    ' Resolve the default appearance of the scrollbar control
    ' -------------------------------------------------------

    ' Initialize the appearance data structure		
    appData = New AppearanceData()

    ' Specify which appearance properties we want to resolve.
    ' In this case just the backcolor and forecolor.
    requestedProps = AppearancePropFlags.BackColor Or AppearancePropFlags.ForeColor

    ' Call the control's 'ResolveAppearance' method .
    Me.ultraScrollBar1.ResolveAppearance(appData, requestedProps)

    ' Write out the resolved colors
    Debug.WriteLine("BackColor: " + appData.BackColor.ToString() + ", ForeColor: " + appData.ForeColor.ToString())

    ' -------------------------------------------
    ' Resolve the appearance of scrollbar buttons
    ' -------------------------------------------

    ' Re-initialize the appearance data structure 
    appData = New AppearanceData()

    ' Specify which appearance properties we want to resolve.
    ' In this case we want all 'Render' properties. This
    ' includes every property but the 'Cursor' property.
    requestedProps = AppearancePropFlags.AllRender

    ' Call the control's 'ResolveButtonAppearance' method.
    Me.ultraScrollBar1.ResolveButtonAppearance(appData, requestedProps)

    ' Write out the resolved gradient related properties.
    Debug.WriteLine("BackGradientStyle: " + appData.BackGradientStyle.ToString() + ", BackColor: " + appData.BackColor.ToString() + ", BackColor2: " + appData.BackColor2.ToString())


    ' There are also methods for resolving the appearance
    ' of the thumb and the track area.
    'Me.ultraScrollBar1.ResolveScrollThumbAppearance( ref appData, ref requestedProps )
    'Me.ultraScrollBar1.ResolveScrollTrackAppearance( ref appData, ref requestedProps )

End Sub
using System.Diagnostics;
using Infragistics.Win;
using Infragistics.Win.UltraWinScrollBar;

private void button1_Click(object sender, System.EventArgs e)
{

	AppearanceData appData;
	AppearancePropFlags requestedProps;

	// -------------------------------------------------------
	// Resolve the default appearance of the scrollbar control
	// -------------------------------------------------------

	// Initialize the appearance data structure		
	appData = new AppearanceData();

	// Specify which appearance properties we want to resolve.
	// In this case just the backcolor and forecolor.
	requestedProps = AppearancePropFlags.BackColor | AppearancePropFlags.ForeColor;

	// Call the control's 'ResolveAppearance' method .
	this.ultraScrollBar1.ResolveAppearance( ref appData, ref requestedProps );
	
	// Note: The reason that the 'requestedProps' parameter
	// is also passed in by reference is that as each requested
	// property is resolved its bit is stripped out of the
	// passed in parameter. On return from the call the only
	// bits remaining in 'requestedProps' will be those 
	// properties which were not resolved. Normally,
	// 'requestedProps' has no bits set after the call returns.

	// Write out the resolved colors
	Debug.WriteLine("BackColor: " + appData.BackColor.ToString() + ", ForeColor: " + appData.ForeColor.ToString() );

	// -------------------------------------------
	// Resolve the appearance of scrollbar buttons
	// -------------------------------------------

	// Re-initialize the appearance data structure 
	appData = new AppearanceData();
	
	// Specify which appearance properties we want to resolve.
	// In this case we want all 'Render' properties. This
	// includes every property but the 'Cursor' property.
	requestedProps = AppearancePropFlags.AllRender;

	// Call the control's 'ResolveButtonAppearance' method.
	this.ultraScrollBar1.ResolveButtonAppearance( ref appData, ref requestedProps );

	// Write out the resolved gradient related properties.
	Debug.WriteLine("BackGradientStyle: " + appData.BackGradientStyle.ToString() + ", BackColor: " + appData.BackColor.ToString() + ", BackColor2: " + appData.BackColor2.ToString() );

		
	// There are also methods for resolving the appearance
	// of the thumb and the track area.
	//this.ultraScrollBar1.ResolveScrollThumbAppearance( ref appData, ref requestedProps );
	//this.ultraScrollBar1.ResolveScrollTrackAppearance( ref appData, ref requestedProps );

}
参照