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

  • Home
  • SEARCH
  • 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 6023763
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T04:03:14+00:00 2026-05-23T04:03:14+00:00

I created a UITableView and wrote the following code in cellForRowAtIndexPath static NSString *CellIdentifier

  • 0

I created a UITableView and wrote the following code in cellForRowAtIndexPath

static NSString *CellIdentifier = @"RootViewControllerCellIdentifier";

UITableViewCell *cell = [self.tableView queueReusableCellWithIdentifier:CellIdentifier];

if (cell == nil) {
    cell = [[[UITableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:CellIdentifier] autorelease];

    cell.selectionStyle = UITableViewCellSelectionStyleGray;    

}

// Set appropriate labels for the cells.
switch (indexPath.row) {
    case 0:
        cell.textLabel.text = @"Static Scenes";             
        **[cell.textLabel setFrame:CGRectMake(200, 20, 500,600)];**
        cell.imageView.image=[UIImage imageNamed:@"RunOptionsImage.png"];
        cell.imageView.frame=CGRectMake(15, 20, 55, 65);
        break;

as you can understand from the above code, i have a tableview cell textLabel named as Static Scenes .

in this code [cell.textLabel setFrame:CGRectMake(200, 20, 500,600)]; i am planning to set the frame of textLabel.but it not resizing according to the frame i set.
i used this cell.textLabel.frame = CGRectMake(200, 20, 500,600) code also.
can any one tell me a good way to re size the text label.

  • 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-23T04:03:15+00:00Added an answer on May 23, 2026 at 4:03 am

    In addition to altering the text label’s size you will also need to return an appropriate height in the tableView:heightForRowAtIndexPath: method. Otherwise, any layout changes won’t reflect.

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

Sidebar

Related Questions

A (when the cell is newly created): - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath {
A (when the cell is newly created): - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath {
Assuming self.tableView is a UITableView instance variable that I created, can anyone explain the
I have my uitableview created with grouped style.. I wish from my code set
I have setup a UITableView (320 wide) with a UITableViewCell created in IB, the
I am showing comments in UItableView and created delete button in Cell..When I delete
I have created a UITableView with two cells, username and password using the code
I have successfully created a UITableView/UITableViewCell that is able to slide up and down
I've created a nib for a custom UITableView cell and followed the documentation and
I have a UITableView with custom cell. I have created seperate class with xib

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.