开发者

How do I show a modalviewcontroller well in a tableview

I need to show a modal view controller when users click a info button on the t开发者_如何转开发op right of my application.


Add an action which you link to a rightBarButtonItem in your navigation controller, or toolbar, whatever you're using -- wherever you want to put it. Anyway, when you set up your button, you want to make sure that when the user presses it, it calls your action.

In the action, you need to create an instance of another view controller which references your modal view, and you want to tell your nav controller to presentModalViewController:animated: your view controller you just created.

Doing this, your modal view will pop up and display.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜