どうやってロードするのですか?テーブルビューの行をクリックしてXIB?以下の例は、クラスの一部です。このクラスのロードを警告しますか?
public override void RowSelected (UITableView tableView, NSIndexPath indexPath)
{
tableView.DeselectRow (indexPath, true);
//this.PresentModalViewController(home,true);
}
どうやってロードするのですか?テーブルビューの行をクリックしてXIB?以下の例は、クラスの一部です。このクラスのロードを警告しますか?
public override void RowSelected (UITableView tableView, NSIndexPath indexPath)
{
tableView.DeselectRow (indexPath, true);
//this.PresentModalViewController(home,true);
}
あなたの質問とコメントには詳細があまりありません...
メソッドの場合override、新しいタイプを右RowSelectedから継承している可能性がありますか? UITableViewSourceその場合は、そのコンストラクターに への参照を保持させ、UITableViewControllerこの参照を使用して後で呼び出す必要がありますPresentModalViewController。
例えば
public class MyTableViewSource : UITableViewSource {
UITableViewController ctrl;
public MyTableViewSource (UITableViewController c)
{
ctrl = c;
}
public override void RowSelected (UITableView tableView, NSIndexPath indexPath)
{
tableView.DeselectRow (indexPath, true);
var home = new UIViewController ("YouNibName", null); // default bundle
ctrl.PresentModalViewController (home, true);
}
}
注: 私は使用UIViewControllerしましたが、NIB 用に定義されたタイプが既にある可能性があります。