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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 18, 20262026-06-18T14:44:02+00:00 2026-06-18T14:44:02+00:00

I have created a UIPopoverController and added it to a main view controller when

  • 0

I have created a UIPopoverController and added it to a main view controller when clicking an setReminder button popoverView working fine. i want dismiss popupview if i click a save button how can i do?
enter image description here

  **mainView.m**
-(void)btnSetReminderTapped:(id)sender
{
setReminderView =[[setReminder alloc]initWithNibName:@"setReminder" bundle:[NSBundle mainBundle]];

setReminderView.delegate = self;
FPPopoverController *popover = [[FPPopoverController alloc] initWithViewController:setReminderView];
popover.tint = FPPopoverDefaultTint;

if(UI_USER_INTERFACE_IDIOM() == UIUserInterfaceIdiomPad)
{
    popover.contentSize = CGSizeMake(400,400);
}
else {
    popover.contentSize = CGSizeMake(320, 288);
}
popover.arrowDirection = FPPopoverArrowDirectionUp;

//sender is the UIButton view
[popover presentPopoverFromView:sender];
}

  ***setReminder.m***

- (IBAction) btnSaveTapped:(id) sender
{

}
  • 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-18T14:44:03+00:00Added an answer on June 18, 2026 at 2:44 pm

    Use delegate to notify your main view on btnSave action and dismiss in that delegate.

    @protocol EventDelegate <NSObject>
    
    - evenSaveButtonClicked;
    
    @end
    

    In your main ViewController implement it as

    - (void) eventSaveButtonClicked{
        [popover dissmissPopoverAnimated:YES];
    }
    
    -(void)btnSetReminderTapped:(id)sender
    {
    setReminderView =[[setReminder alloc]initWithNibName:@"setReminder" bundle:[NSBundle mainBundle]];
    setReminder.delegate = self;
    setReminderView.delegate = self;
    FPPopoverController *popover = [[FPPopoverController alloc] initWithViewController:setReminderView];
    popover.tint = FPPopoverDefaultTint;
    
    if(UI_USER_INTERFACE_IDIOM() == UIUserInterfaceIdiomPad)
    {
        popover.contentSize = CGSizeMake(400,400);
    }
    else {
        popover.contentSize = CGSizeMake(320, 288);
    }
    popover.arrowDirection = FPPopoverArrowDirectionUp;
    
    //sender is the UIButton view
    [popover presentPopoverFromView:sender];
    }
    

    You have to create a delegate inside your SetReminder Class

    @interface SetReminder
    
    @property(nonatomic, unsafe_unretain) id<EventDelegate> delegate
    
    @end
    

    and in implementation file(.m) you can sythesis it as follow

    @implementation SetReminder
    @synthesis delegate
    
    // Your button save code
    - (IBAction) btnSaveTapped:(id) sender
        {
             if([delegate respondToSelector:@selector(eventSaveButtonClicked)]){ 
                 [delegate eventSaveButtonClicked];
             }
        }
    

    @end

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

Sidebar

Related Questions

I have created a UIPopoverController and added it to a view controller when clicking
I have created a view controller, and added a table view as a subview
Have created a small two tab app, then subclassed another view controller to create
I have created a viewcontroller and have added some labels and a button to
This has me scratching my head. I have a view controller that implements UIPopoverControllerDelegate
I have created sample application that insert 12 rows in tableview.And inserted fine.When after
I have a UITableView which I present in a UIPopoverController . The table view
I'm working with popover, inside the popover have contain a uitableview, and i want
I have opened a pop up window on button click. I want to set
I have created a tableview with grouped style. I have added this table to

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.