Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

chrono1081

macrumors G3
Original poster
Jan 26, 2008
8,811
5,751
Isla Nublar
Hi guys,

I've been pulling my hair out for a few hours trying to get a UIPopover to display when I hit a button, thats all I want. I need to put it in a storyboard for work requirements but I can't find any tutorials that show how to do this. Apples default Utility app is what I'd ideally like to mimic only with a button instead of a tab bar. Every tut I've tried is either 30+ minutes long and does it programmatically, or doesn't work.

All I need is this:

-Create a UIPopover that displays when I click a button, all done with storyboards. (I'll worry about functionality later)

Here's what I've tried that got me the closest to what I want:

-Create a default storyboard.
-Create a new view controller.
-Draw a segue between them and choose popover as the type
-Create an anchor to the button
-Give it an identifier (I'm not really clear what this does).
-And this is where I'm stuck.

I know there are ways to do this programmatically but again, for work reasons it has to be in the storyboard and I can't find a single tutorial that shows me the most basic way to do that with the most minimal amount of coding. Can anyone give me any suggestions? Apples docs do not show how to do this in a storyboard like the default utility app and since I'm using a button I don't have the convenience method that launches it from the tab bar.

Surely this isn't a difficult thing is it?
 
Hi guys,

I've been pulling my hair out for a few hours trying to get a UIPopover to display when I hit a button, thats all I want. I need to put it in a storyboard for work requirements but I can't find any tutorials that show how to do this. Apples default Utility app is what I'd ideally like to mimic only with a button instead of a tab bar. Every tut I've tried is either 30+ minutes long and does it programmatically, or doesn't work.

All I need is this:

-Create a UIPopover that displays when I click a button, all done with storyboards. (I'll worry about functionality later)

Here's what I've tried that got me the closest to what I want:

-Create a default storyboard.
-Create a new view controller.
-Draw a segue between them and choose popover as the type
-Create an anchor to the button
-Give it an identifier (I'm not really clear what this does).
-And this is where I'm stuck.

I know there are ways to do this programmatically but again, for work reasons it has to be in the storyboard and I can't find a single tutorial that shows me the most basic way to do that with the most minimal amount of coding. Can anyone give me any suggestions? Apples docs do not show how to do this in a storyboard like the default utility app and since I'm using a button I don't have the convenience method that launches it from the tab bar.

Surely this isn't a difficult thing is it?

Could you upload the project you've described? I'll have a look around and see if I can figure out what's going wrong.
 
Could you upload the project you've described? I'll have a look around and see if I can figure out what's going wrong.

Thank you for the offer, I figured it out. I was being EXTREMELY stupid....


....

....I basically was control dragging from the view itself instead of the button the pop up was to display next to and creating the segue that way...

I'm going to go hide now...
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.