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 6915153
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T09:26:21+00:00 2026-05-27T09:26:21+00:00

Well, in my application there is textfield, which contains some date. Textfield is not

  • 0

Well, in my application there is textfield, which contains some date. Textfield is not editable for user, but it calling for popover with calendar (Tapku Calendar, BTW). I need to paste selected date in calendar into this textfield. I’v trying this code, but it didn’t working for me.

Code in Calendar_Popover_Controller.m:

// grab (NSString*)Date from calendar and sending it to ChekIn field
- (void)calendarMonthView:(TKCalendarMonthView *)monthView didSelectDate:(NSDate *)d {

NSDate *calendarSelectedDate = [[NSDate alloc] init];
/* Here is formattedDate */

calendarSelectedDate = [calendar dateSelected];
DateForMainView = [formattedDate stringFromDate:calendarSelectedDate];

ViewController *submittedDateToMainView = [[ViewController alloc] init];
submittedDateToMainView.CheckInField.text = [formattedDate stringFromDate:calendarSelectedDate];
}

Also I’ve check other variant. It seems like this:

Calendar_Popover_Controller.m

- (void)calendarMonthView:(TKCalendarMonthView *)monthView didSelectDate:(NSDate *)d {

NSDate *calendarSelectedDate = [[NSDate alloc] init];;
/* formattedDate */

calendarSelectedDate = [calendar dateSelected];
DateForMainView = [formattedDate stringFromDate:calendarSelectedDate];
ViewController *submittedDateToMainView = [[ViewController alloc] init];
submittedDateToMainView.DateFromCalendar = DateForMainView;
}

Code in ViewController.m:

- (BOOL)popoverControllerShouldDismissPopover:(UIPopoverController *)popoverController {
[CheckInField setText:DateFromCalendar];

NSLog(@"For CheckIn TextField DateFromCalendar is: %@", DateFromCalendar);
NSLog(@"popover about to be dismissed");
return YES;
}

Here DateFromCalendar == nil anyway. I have no idea to solve this problem.

  • 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-05-27T09:26:22+00:00Added an answer on May 27, 2026 at 9:26 am

    The ViewController you are using in the calendarMonthView:didSelectDate: method is not the one showing on the screen, because you initialize a new one when doing

    ViewController *submittedDateToMainView = [[ViewController alloc] init];

    You need to keep a reference to your existing ViewController in your Calendar_Popover_Controller and set the DateFromCalendar on that one.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

We have an application (well, 3) which uses Oracle 9i, however this is being
My application uses several threads with well-defined names (i.e. not a thread pool with
As the title suggests, I've inherited a php/MySQL application which has fairly well written
I have a simple cocoa application with an editable textfield text1 at the top
I've a web application (well, in fact is just a servlet) which receives data
I am interested in starting Mobile application Development.There are many suggestions on internet but,I
I'm writing a small audio application (in Silverlight, but that's not really relevant I
Is there a distributed application framework (commercial is okay as well) that supports iPhone
Our application is well structured (well we did our best!) and we have split
So I feel I pretty well understand the application layer, and everything below (and

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.