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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T10:16:04+00:00 2026-05-31T10:16:04+00:00

I have a UITableView wherein I have placed a UIButton (as a subview of

  • 0

I have a UITableView wherein I have placed a UIButton (as a subview of cell). Also below the table, I have a UITextField. On touching the textField, the keypad appears as usual. What I want is to dismiss the keypad on touching the table.

One option which I considered was setting UITapGestureRecognizer for UITableView. But I threw up that idea as I have a button on tableCell which then becomes unresponsive.

Also, I don’t want Done or return button on keypad. What I mean to say is, I don’t want the keypad to disappear from keypad but on touching the table taking care of the button it has.

  • 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-31T10:16:06+00:00Added an answer on May 31, 2026 at 10:16 am

    May be you can try this.

    //NSnotification when keyboard is shown
    - (void)keyboardWasShown:(NSNotification  *)notification
    {    
        //  Get the size of the keyboard.
        if(UI_USER_INTERFACE_IDIOM()==UIUserInterfaceIdiomPhone){
    
            if(UIInterfaceOrientationPortrait==orientation || UIInterfaceOrientationPortraitUpsideDown==orientation){
                keyboardSize=CGSizeMake(320.000000, 216.000000);
            }
         else if(UIInterfaceOrientationLandscapeLeft==orientation || UIInterfaceOrientationLandscapeRight==orientation)
            {
                keyboardSize=CGSizeMake(162.000000, 480.000000);
            }
        }
        else if(UI_USER_INTERFACE_IDIOM()==UIUserInterfaceIdiomPad){
            if(UIInterfaceOrientationPortrait==orientation || UIInterfaceOrientationPortraitUpsideDown==orientation)
                keyboardSize=CGSizeMake(768.000000, 264.000000);        
    
            else if(UIInterfaceOrientationLandscapeLeft==orientation || UIInterfaceOrientationLandscapeRight==orientation)
            {
                keyboardSize=CGSizeMake(352.000000,1024.000000);
    
            }
        }
    
        //  Adjust the bottom content inset of your scroll view by the keyboard height.
        UIEdgeInsets contentInsets = UIEdgeInsetsMake(0.0, 0.0, keyboardSize.height, 0.0);
        scrvwLogig.contentInset = contentInsets;
        scrvwLogig.scrollIndicatorInsets = contentInsets;
    
        // Scroll the target text field into view.
        CGRect aRect = self.view.frame;
        aRect.size.height -= keyboardSize.height;
        if (!CGRectContainsPoint(aRect, txtpassword.frame.origin) ) {
    
            CGPoint scrollPoint=CGPointZero;
            //check flag for iPhone orientation
            if(flgLandScape)        
               scrollPoint = CGPointMake(0.0, txtpassword.frame.origin.y-70);
            //check flag for iPhone/iPad orientation
            else if(flgPort || flgPortiPad)
               scrollPoint = CGPointMake(0.0, txtpassword.frame.origin.y - (keyboardSize.height-50));        
            //check flag for ipad orientation
             else if(flgLandScapeiPad)        
              scrollPoint = CGPointMake(0.0, txtpassword.frame.origin.y-130);  
    
            [scrvwLogig setContentOffset:scrollPoint animated:YES];
        }
    }
    
    
    //when keyboard is hide
    
    - (void) keyboardWillHide:(NSNotification *)notification {
    
        UIEdgeInsets contentInsets = UIEdgeInsetsZero;
        scrvwLogig.contentInset = contentInsets;
        scrvwLogig.scrollIndicatorInsets = contentInsets;
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have UITableView and cell's are customized and have a UIImage with UIbutton, UIlabel
I have an app wherein the datasource for a UITableView updates by a background
I have a UITableView cell that is going to have a variable size depending
I have a UITableView that displays single large images in each cell. The names
I have a uitableview that loads fairly large images in each cell and the
I have a UITableView that I have set-up with 2 sections. The code below
I have UITableView with cells. Cell contains image, label and detail label. Then I've
I have UItableview where every cell containing 5 cell and these cell are representing
Hi i have UITableView with x rows and my cell data loaded with plist
I have a UITableView with custom UITableViewCells. The table has two sections, the first

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.