DetailsViewDesigner.SampleRowCount プロパティ
定義
重要
一部の情報は、リリース前に大きく変更される可能性があるプレリリースされた製品に関するものです。 Microsoft は、ここに記載されている情報について、明示または黙示を問わず、一切保証しません。
表示する関連付けられたコントロールのサンプル行の数を取得します。
protected:
virtual property int SampleRowCount { int get(); };
protected override int SampleRowCount { get; }
member this.SampleRowCount : int
Protected Overrides ReadOnly Property SampleRowCount As Integer
プロパティ値
表示するサンプル行の数。
例
次のコード例は、デザイン時にコントロールのポケットベル行に表示されるページ リンクの数を変更するために、クラスからDetailsViewDesigner継承されたクラスのプロパティをオーバーライドSampleRowCountする方法をDetailsView示しています。 この例では、5 つのページ リンクが表示されます。
// Determines the number of page links in the pager row
// when viewed in the designer.
protected override int SampleRowCount
{
get
{
// Render five page links in the pager row.
return 5;
}
} // SampleRowCount
' Determines the number of page links in the pager row
' when viewed in the designer.
Protected Overrides ReadOnly Property SampleRowCount() As Integer
Get
' Render five page links in the pager row.
Return 5
End Get
End Property ' SampleRowCount
注釈
このプロパティは SampleRowCount 常に数値 2
を返します。 これにより、デザイン時にコントロールのポケットベル行に 2 つのページ リンクが DetailsView 表示されます。