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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 14, 20262026-05-14T14:11:47+00:00 2026-05-14T14:11:47+00:00

I have a UIView with another UIView inside it. On the inside UIView there

  • 0

I have a UIView with another UIView inside it. On the inside UIView there is a textbox which I want to fill in. When I try to fill it in the keyboard blocks my view:

The UIViewController has the following

containerView = [[UIView alloc] initWithFrame:[UIScreen mainScreen].bounds];
self.view=containerView;
//The apropriate releases etc are further on...

When I touch it, the keyboard comes up as expected, but blocks the textbox I’m trying to fill in. How can I force the view to slide up?

The front view

OptionsFront * fv = [[OptionsFront alloc] initWithFrame:[UIScreen mainScreen].bounds];
[containerView addSubview:frontView];

In the front view is a subview

CGRect bounds = CGRectMake(0.0f, 210.0f, 280.0f, 130.0f);
sv = [[UIView alloc] initWithFrame:bounds];
[self addSubview:sv]; //added to frontView

In sv is a textbox near the botton:

rect = CGRectMake(70.0f, 20.0f, 100.0f, 27.0f);
cf = [self createTextField_Rounded:rect holder:@"+ve"];
[sv addSubview:cf];

So cf happens to be near the bottom of the page. I expected that when I select it, the whole display would move up, but the keyboard just moves up and blocks it.

What can I do?

Appendix:

- (UITextField *)createTextField_Rounded:(CGRect) frame holder:(NSString *) ph
{
UITextField *returnTextField = [[UITextField alloc] initWithFrame:frame];
returnTextField.borderStyle = UITextBorderStyleRoundedRect;
    returnTextField.textColor = [UIColor blackColor];
returnTextField.font = [UIFont systemFontOfSize:17.0];
returnTextField.delegate = self;
returnTextField.keyboardType = UIKeyboardTypeNumbersAndPunctuation;
returnTextField.returnKeyType = UIReturnKeyDone;

returnTextField.clearButtonMode = UITextFieldViewModeWhileEditing;

return returnTextField;
}
  • 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-14T14:11:47+00:00Added an answer on May 14, 2026 at 2:11 pm

    you need to move the textField up. in your UITextField delegate implement something like (from memory):

    - (void)textFieldDidBeginEditing:(UITextField *)textField {
        [UIView beginAnimations:nil context:NULL];
        [UIView setAnimationDuration:0.3];
        textField.superview.frame = CGRectMake(0.0f, 100.0f, 280.0f, 130.0f); // experiment with frame size
        [UIView commitAnimations];
    }
    

    and you’ll want to move it back in textFieldDidEndEditing:

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

Sidebar

Related Questions

I have a UIImageView which is inside another UIView. I rotate the UIImageView with
I have a UIView on top of another view that's using a UITouchGesture. The
I have a UIView(first view) on top of which I would like to display
I have one single MainViewController which has of course it's one main UIView. I
I have an uiview A inside another uiview B. A contains many other ui
I have declared a UIView inside a UIViewController class. Can I call this UIView
I have this UIScrollView inside another UIView, not occuping the entire area (all this
I have nested a navigation controller inside another and now its causing the uiview
I have a NIB that contains a UIView. I have another NIB that contains
I have a UIView, it is not inside UIScrollView. I would like to move

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.