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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T18:43:44+00:00 2026-06-10T18:43:44+00:00

i have downloaded one nice sample code UAModalPanel . i have implemented it in

  • 0

i have downloaded one nice sample code UAModalPanel. i have implemented it in my project, if we tap segment control’s first index it will open the UAModalPanel. i could successfully implemented this one.

But if we select second or third index in segment control i need to close the UAModalPanel How can i achieve this. if anyone knows guide me?

enter image description here
if we tap the segment control below will be called

   -(void)navBarSegmentCntrl_tapped
{
if(navBarSegmentCntrl.selectedSegmentIndex==0)
{

    UAExampleModalPanel *modalPanel = [[UAExampleModalPanel alloc] initWithFrame:self.view.bounds title:@"dfg" ];



    [self.view addSubview:modalPanel];

    // Show the panel from the center of the screen
    [modalPanel showFromPoint:self.view.center];



}
else if(navBarSegmentCntrl.selectedSegmentIndex==1)
{
    [UAmodal hide];  //UAmodal allocated in view didload//
    imagePickerController = [[UIImagePickerController alloc] init];
    imagePickerController.delegate = self;
    imagePickerController.sourceType = 
    UIImagePickerControllerSourceTypePhotoLibrary;

    [self presentModalViewController:imagePickerController animated:YES];   
}

}

  • 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-10T18:43:45+00:00Added an answer on June 10, 2026 at 6:43 pm

    The problem is that the object that you are calling show is not the same one your are calling hide. You should declare it in your interface file:

    @interface MyViewController : UIViewController
    {
        UAModalPanel *myModalPanel;
    }
    

    And then, when you show it in navBarSegmentCntrl_tapped method, you init this myModalPanel (remember you don’t need to do UAModalPanel *myModalPanel again, once you already set it up, and your view controller is “already aware of the object”. You just do myModalPanel = [[UAModalPanel alloc] init....).

    Then, to hide it, just call [myModalPanel hide];.

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

Sidebar

Related Questions

I have downloaded follwing code from one of Google Codes but problem is in
I have downloaded one ImageDownloader code from gitHub( from Here ) Now when I
I have downloaded the webworks sdk 2.3.0.9 because the latest one will not compile
Hey I have downloaded one of the xml editors from some site. But don't
I am trying to make a Postgres PHP backup script. I have downloaded one
I have two linux boxes. Both Fedora 11 x64. On one, I downloaded the
I have prepared one sample application.When application install in devices download the file from
I have Ubuntu Linux. I found one command will let me download unread message
Im looking for a nice demo/sample using Windows Mobile Managed Gestures. I have a
One of the nice feature of the Image control is that we can specified

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.