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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T15:23:55+00:00 2026-05-27T15:23:55+00:00

I have a custom UIScrollView in my app. When the user touches the scroll

  • 0

I have a custom UIScrollView in my app. When the user touches the scroll view I want it to enlarge to fill the entire screen.

I have tried using this code, however nothing happens :

-(void) touchesBegan: (NSSet *) touches withEvent:(UIEvent *) event {

NSLog(@"Touch Detected");
self.frame = CGRectMake(0, 0, 768, 1024);

}

Is there a way to dynamically change the size of the view ? Also is it possible to somehow animate the change in size ?

Thank you in advance.

  • 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-27T15:23:56+00:00Added an answer on May 27, 2026 at 3:23 pm

    Your code looks correct. Perhaps your view is clipped within a parent view making it seem as though it didn’t resize, in which case you should be mindful of the clipsToBounds property of the parent view. Some other considerations (without knowing what makes you think its not working) is the contentMode property of your UIScrollView. Depending on that value, your UIScrollView may not be redrawing itself. See UIView for details (read frame property)

    Animate example:

    [UIView animateWithDuration:<some float value in seconds> animations:^{
    
        self.frame = CGRectMake(0, 0, 768, 1024);
    
    }];
    

    Details on animate: UIView (read animateWithDuration:animations: class method).

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

Sidebar

Related Questions

I have a UIScrollView . This scroll view scrolls my custom GameView . When
I have a Custom Scroll View, subclassing UIScrollView . I have added a scroll
I have custom classes that I currently instantiate within App.xaml as resources. I want
I have a UIScrollView with a custom content view that uses drawRect to display
I want to have a custom view at the top of my UITextView that
In my iPhone app I have a UIScrollView with custom content views. At some
I have custom view in my application which can be scrolled by the user.
We have custom headers in the Silverlight DataGrid using the ContentTemplate. We've got a
In my app, I'm designing a custom picker that allows the user to choose
I currently have a simple iPhone app that loads a custom subclass of UIView.

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.