UITableView.SelectRow(NSIndexPath, Boolean, UITableViewScrollPosition) メソッド

定義

指定した行を選択し、オプションで行を特定の場所までスクロールします。

[Foundation.Export("selectRowAtIndexPath:animated:scrollPosition:")]
public virtual void SelectRow (Foundation.NSIndexPath indexPath, bool animated, UIKit.UITableViewScrollPosition scrollPosition);
abstract member SelectRow : Foundation.NSIndexPath * bool * UIKit.UITableViewScrollPosition -> unit
override this.SelectRow : Foundation.NSIndexPath * bool * UIKit.UITableViewScrollPosition -> unit

パラメーター

indexPath
NSIndexPath

選択する行を識別します。

このパラメーターは、null に設定できます。

animated
Boolean

true 変更が直ちに発生する必要がある場合は、 false 選択と位置の変更をアニメーション化します。

scrollPosition
UITableViewScrollPosition

選択した行をスクロールする位置 (上、中央、下)。

属性

を渡します None。 はスクロールしません (通常、その定数が最小限のスクロールを引き起こしているにもかかわらず)。 最小スクロールで新しく選択した行にスクロールするには、このメソッドNoneを使用して行を選択し、 を使用して もNone呼び出ScrollToRow(NSIndexPath, UITableViewScrollPosition, Boolean)します。

NSIndexPath rowToSelect; // assume this is valid
UITableView myTableView; // assume this is valid

myTableView.SelectRow (rowToSelect, true, UITableViewScrollPosition.None);
myTableView.ScrollToRow (rowToSelect, UITableViewScrollPosition.None, true);

注釈

このメソッドを呼び出しても、トリガー WillSelectRow(UITableView, NSIndexPath) も通知も送信 SelectionDidChangeNotification されません。

適用対象