現在のセルまたは現在の行を移動する方法

文書番号 : 25920     文書種別 : 使用方法     最終更新日 : 2008/06/27
文書を印刷する
対象製品
MultiRow for Windows Forms 5.0J
詳細
現在のセル(カレントセル)と現在の行(カレント行)の情報は、GcMultiRow.CurrentCellPosition プロパティに保持されています。

現在の行を維持したまま、現在のセルだけを移動するには次のようにコーディングします。

[Visual Basic]
Imports GrapeCity.Win.MultiRow

Dim pos As CellPosition = GcMultiRow1.CurrentCellPosition
GcMultiRow1.CurrentCellPosition = New CellPosition(pos.RowIndex, pos.CellIndex + 1)

[C#]
using GrapeCity.Win.MultiRow;

CellPosition pos = gcMultiRow1.CurrentCellPosition;
gcMultiRow1.CurrentCellPosition = new CellPosition(pos.RowIndex, pos.CellIndex + 1);

現在のセルを維持したまま、現在の行だけを移動するには次のようにコーディングします。

[Visual Basic]
Imports GrapeCity.Win.MultiRow

Dim pos As CellPosition = GcMultiRow1.CurrentCellPosition
GcMultiRow1.CurrentCellPosition = New CellPosition(pos.RowIndex + 1, pos.CellIndex)

[C#]
using GrapeCity.Win.MultiRow;

CellPosition pos = gcMultiRow1.CurrentCellPosition;
gcMultiRow1.CurrentCellPosition = new CellPosition(pos.RowIndex + 1, pos.CellIndex);

この文書は、以前は次のFAQ IDで公開されていました : 11293