Ccna final exam - java, php, javascript, ios, cshap all in one. This is a collaboratively edited question and answer site for professional and enthusiast programmers. It's 100% free, no registration required.
Tuesday, January 17, 2012
Date Picker And Table View
I'm working on a project on iPhone and I want a Date Picker on a few of the rows in the table view.
If this is a StaticCell TablieView, then you can just add these via storyboard.
If not, you will need to use the cellForRowAtIndexPath to determine which cell you want to add the datepicker to. You would then instantiate a UIDatePicker, set the attributes if needed and add that subview to your cell.
One warning - using something this large in an iPhone TableView app will result in a crappy user experience.
If this is a StaticCell TablieView, then you can just add these via storyboard.
ReplyDeleteIf not, you will need to use the cellForRowAtIndexPath to determine which cell you want to add the datepicker to. You would then instantiate a UIDatePicker, set the attributes if needed and add that subview to your cell.
One warning - using something this large in an iPhone TableView app will result in a crappy user experience.