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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 18, 20262026-06-18T10:50:24+00:00 2026-06-18T10:50:24+00:00

In my project I have enabled AutoLayout in order to make the app scale

  • 0

In my project I have enabled AutoLayout in order to make the app scale properly in both iPhone 4 and iPhone 5. Everything worked fine with doing so, but I found a new problem which I am not sure how to handle.

In my project I have a normal method which checks if a boolean is yes or no, if yes the interface should add a button into the interface and keep my tableView in its current state. But if the method returns no, the button should disappear and make the tableView’s height higher! Everything with the button works fine but for some reason after start using AutoLayout my code for increasing the tableView’s height stopped working (which worked before).

Now what can I do to make my tableView’s height increase in height even if I am using AutoLayout? Here is my code:

- (void)viewWillAppear:(BOOL)animated
{
NSString *bookName = [self getCurrentBookName];

if([self isBlank:bookName])
{
    [self.currentBookLabel setText:NSLocalizedString(@"LabelNoBookChosen", nil)];
}
else
{
    [self.currentBookLabel setText:[self getCurrentBookName]];
}

[super viewWillAppear:animated];

  if([self isAppLicensed] != YES)   <------------------THIS IS WHERE I CHECK THE BOOLEAN METHOD!
{
    [actionAppStore setHidden:TRUE];

    CGRect framez =  [tableView frame]; <------------------ THIS CODE IS NOT WORKING ANY LONGER!
    [tableView setFrame:CGRectMake(framez.origin.x, framez.origin.y, framez.size.width, framez.size.height+77)];
}    
else
{
    [actionAppStore setHidden:FALSE];
}
}
  • 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-18T10:50:25+00:00Added an answer on June 18, 2026 at 10:50 am

    You probably need to tell the view to layout its subviews using layoutIfNeeded.

    See my question I just solved and this question is also related.

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

Sidebar

Related Questions

My project is ARC enabled (the build settings have Objective-C Reference Counting set to
I have created a project in Dashcode, inserted a List control, enabled a dynamic
I have a submodule in a project in Jenkins. I've enabled the advanced setting
I cannot import a maven project with WTP features enabled. I have already tried:
I have a WPF project which compiles just fine. However, when I enable code
I've started a new project and have decided to make sure it builds cleanly
I have WCF service running on netTcpBinding, everything fine I have some more functions
I have a Silverlight 4 Business Project where I have enabled the ASP.NET Authentication/Authorization
I have the following project setup: Two libraries 'commoncomponents' and 'libs' that both have
I have a maven enabled project imported into Eclipse. From Eclipse, I get 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.