I'm diving into iPhone OS development on the iPad and one of the things I'm playing with is the SplitView template. The template provides a window with a UISplitView view, containing the Root View (on the left of the window) and the Detail View (on the right of the window). The Root View is a subclass of a TableView. Rather than having the entire Root View consist of a TableView, I'd like it to contain a DatePicker view along with the TableView under it. When I go into IB and try and drop a DatePicker into the Root View, it won't let me. It will only let me add a DatePicker view to the Detail View.
- Why wont IB let me drop a DatePicker view into the Root View?
- How can I add a DatePicker to the RootView in addition to the TableView?
I'm still learning this new platform, so I apologize if these questions are absurd in any way. Thanks so much in advance for your help, I'm going to continue r开发者_开发问答esearching these questions right now.
Why wont IB let me drop a DatePicker view into the Root View?
For starters, RootViewController is a UITableView. You can't add a UIDatePicker to a UITableView.
How can I add a DatePicker to the RootView in addition to the TableView?
If you want to add a UIDatePicker, you have to replace RootViewController with a UIViewController then add a UITableView and UIDatePicker.
精彩评论