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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T04:18:10+00:00 2026-06-14T04:18:10+00:00

I have a UIActionSheet that works just fine on the iPhone simulator. It is

  • 0

I have a UIActionSheet that works just fine on the iPhone simulator. It is presented when the user touches a UIButton.

Using the iPad, I believe UIActionSheets are wrapped into a UIPopupController.

When I call the same code using the iPad simulator, I get a thin “line” displayed, which looks like a UIPopupController (you can see the small arrow that usually points to a control). None of the content can be seen.

What is the correct way to use a UIActionSheet using the iPad with MonoTouch? Here is a bit of sample code I have been testing with – creating the UIActionSheet:

var actionSheet = new UIActionSheet () { Style = UIActionSheetStyle.BlackTranslucent };
        actionSheet.Frame = actionSheetFrame;
        actionSheet.Clicked += (s, e) => { Console.WriteLine ("Clicked on item {0}", e.ButtonIndex); };
actionSheet.AddSubview (doneButton);

Then, I am showing the actionsheet by calling the following from a button:

btnSay.TouchUpInside += (sender, e) => {
            actionSheet.ShowFrom(tmpBtn.Frame, tmpView, false);
        };

I get something like the attached screenshot when using the iPad simulator.

iPad UIActionSheet example

For reference, here is what the UIActionSheet looks like when using the iPhone simulator.

iPhone UIActionSheet example

Note: The project is a universal single-view MonoTouch c# project.

Any pointers or help would be much appreciated!

  • 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-14T04:18:11+00:00Added an answer on June 14, 2026 at 4:18 am

    I faced this same problem with a recent app I released to the app store.

    When you show a UIActionSheet on iPad, iOS wraps the UIActionSheet in a UIPopoverView.

    I used the following code to detect whether this is an iPad, and if it is, adjust the frame of the popover view:

    const int CHROMEWIDTHLEFT = 9;
    const int CHROMEWIDTHRIGHT = 8;
    const int MARGIN = 50;
    
    UIActionSheet _actionSheet;
    
    ...
    
    if (UIDevice.CurrentDevice.UserInterfaceIdiom == UIUserInterfaceIdiom.Pad) {
        var popover = _actionSheet.Superview.Superview;
        if (popover != null)
        {
            var x = _actionSheet.Frame.X + MARGIN;
            var y = (UIScreen.MainScreen.ApplicationFrame.Height - _actionSheet.Frame.Height) / 2;
            var width = _actionSheet.Frame.Width - (MARGIN * 2);
            var height = _actionSheet.Frame.Height;
    
            popover.Frame = new RectangleF (x, y, width, height);
            _actionSheet.Frame = new RectangleF (x, y, width - (CHROMEWIDTHLEFT + CHROMEWIDTHRIGHT), height - (CHROMEWIDTHLEFT + CHROMEWIDTHRIGHT));
        }
    }
    

    The example is based upon the Xamarin ActionSheet Date Picker here

    I have put these up as a Gist (Normal and DatePicker)

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

Sidebar

Related Questions

I have discovered a strange problem when using UIActionSheet on the iPhone (iOS 4.2).
I have some destructive operations that need confirmation, and I'm using the UIActionSheet. Inside
I have an iPhone (Xcode) Project that was working fine. Something must have been
I have a UIActionSheet that pops up as soon as the initial view in
I have a UIActionSheet that displays various buttons, one of which posts a tweet
I have an Action Sheet that is called from my root view controller using
In my iPhone project, I have a navigation view controller. In each view that
I have a UIActionSheet that I created Dynamically and it can have a number
Using Xcode I have View A that navigates to View B. Upon pressing the
I have a question regarding the UIActionSheet on the iPad. When I present an

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.