Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7917113
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T15:02:36+00:00 2026-06-03T15:02:36+00:00

I have an UIView with embedded an UITableView. One text field in the same

  • 0

I have an UIView with embedded an UITableView.
One text field in the same view should control the table’s cells number.
If the user enters the number 4, immediately the TableView should change its cells number to reflect what the user entered.
The content of the cells will just be something like “Please select”.

Then, when the user selects a cell, a Date Picker should come up, let the user choose the date/time and then, when the picker is dismissed, that cell should change to the date/time selected.

I’m going crazy with this since more than two days. I don’t put any code here because I really have no idea where to start and all the things I’ve tried so far were a complete failure.

If anyone can lead me to the solution, I would really appreciate it.
Thanks.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-03T15:02:38+00:00Added an answer on June 3, 2026 at 3:02 pm

    If you’re on the iPad, you could show a UIPopOverController from the selected cell when the user selects it. On an iPhone, you could present a modal view controller.

    For this, see -(void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath.

    You’ll have to implement code that handles getting the value from the UIDatePicker when its presenting view controller is dismissed. Also, you’ll have to host the UIDatePicker in a view controller, as there is no way (as far as I know) to present it on its own.

    So, my proposed solution is:

    1. Create a new view controller that hosts the UIDatePicker you want to present.
    2. On that view controller, put “OK” and “Cancel” buttons.
    3. Add a property to that view controller that references your “main” view controller. This is so that the view controller that hosts the UIDatePicker can send a message to the “main” view controller when you’re done selecting the date.
    4. In your “main” view controller, handle the tableView:didSelectRowAtIndexPath: event for your UITableView.
    5. Present the view controller to show the UIDatePicker to the user.
    6. If the user selects “OK”, dismiss the modal/popOver view controller and update the cell with the new information (you’ll probably need an array of NSDate values and a call to [tableView reloadData] to perform this).
    7. If the user selects “Cancel”, dismiss the modal/popOver view controller and DON’T UPDATE ANYTHING.
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a UIView subclass that I assign to a text field as follows:
I have UIView designed in IB, and UITableView on it. In view contoller's viewDidLoad
I have a UIView called character. Inside that view the user can add several
I have a UIView that contains a number of CALayer subclasses. I am using
I have a UIView container that has two UIImageView s inside it, one partially
I have a UIView in which I added a UITapGestureRecognizer . Inside that view
I have a UIView subclass that programmatically creates and adds a number of subviews.
I have a UIView with multiple text boxes. Now i have used delegates to
I have 3 pickers on my view, one of which contains only images. So,
I have a UIView that I am setting as the property of a UITableView

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.