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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 2, 20262026-06-02T03:53:46+00:00 2026-06-02T03:53:46+00:00

I am having a weird problem and i couldn`t find a solution (or something

  • 0

I am having a weird problem and i couldn`t find a solution (or something similar).
The thing is, my UITableView Populates with initial info (for testing), but no matter what i do i can’t seem to put it to grouped style (i can select it on the UI but it wont show)

I initially started a TabBar project and added a third navigationController view in the tabs.

#import <UIKit/UIKit.h>

@interface RootViewController : UITableViewController <UITableViewDelegate, UITableViewDataSource> {
NSMutableArray *tableData;
}

@property (nonatomic, retain) NSMutableArray *tableData;

-(void)initTableData;

@end

This is the header, and as you can see it has nothing out of the ordinary. The following code is inside the .m file of the header i just posted(ill only be posting uncommented code:

@synthesize tableData;

-(void)initTableData
{
    tableData = [[NSMutableArray alloc] init];
    [tableData addObject:@"Cidade"];
    [tableData addObject:@"Veículo"];
    [tableData addObject:@"Ano"];
    [tableData addObject:@"Valor"];
    [tableData addObject:@"Cor"];
    [tableData addObject:@"Combustível"];
}

- (void)viewDidLoad {
    [super viewDidLoad];
    self.title = @"Busca";
    UIBarButtonItem *_backButton = [[UIBarButtonItem alloc] initWithTitle:@"Back" style:UIBarButtonItemStyleDone target:nil action:nil];
    self.navigationItem.backBarButtonItem = _backButton;
    [self initTableData];
}

- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView {
    // Return the number of sections.
    return 1;
}


- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section {
    // Return the number of rows in the section.
    return 6;
}


// Customize the appearance of table view cells.
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath {

    static NSString *CellIdentifier = @"Cell";

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

    // Configure the cell...
    cell.textLabel.text = [tableData objectAtIndex:[indexPath row]];

    return cell;
}

- (void)dealloc {
    [tableData release];
    [super dealloc];
}

Nothing out of the ordinary again as you can see…
Any idea of what may be causing this? I tried

- (id)initWithStyle:(UITableViewStyle)style {
    // Override initWithStyle: if you create the controller programmatically and want to perform customization that is not appropriate for viewDidLoad.
    self = [super initWithStyle:UITableViewStyleGrouped];
    if (self) {
        // Custom initialization.
    }
    return self;
}

because i don’t know what else to do. (also didn’t worked)
Again, i got the delegate and datasource set to File`s Owner.

- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {    

    // Override point for customization after application launch.

    // Set the tab bar controller as the window's root view controller and display.

    self.window.rootViewController = self.tabBarController;
    RootViewController *rvc = [[RootViewController alloc] initWithStyle: UITableViewStyleGrouped];

    [self.window makeKeyAndVisible];

    return YES;
}
  • 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-02T03:53:47+00:00Added an answer on June 2, 2026 at 3:53 am

    As you have modified the - (id)initWithStyle:(UITableViewStyle)style initializer to return a UITableView with a grouped style, do you call this initializer when you initialize the RootViewController?

    RootViewController *rvc = [[RootViewController] alloc] initWithStyle: UITableViewStyleGrouped];
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm having a weird problem with memset, that was something to do with a
Having a weird problem. I'm testing an ASP.NET application I wrote that queries SQL
I am having this weird problem where everything seems to work as expected but
I'm having the weird problem that after having javascript inject some dom-elements the css-rules
I'm having a weird problem with the following function, which returns a string with
I'm having a weird problem with index organized table. I'm running Oracle 11g standard.
I am having a weird problem with sending data back to my server. This
I am having a weird problem where lots of ^M characters show up in
I'm having a weird problem with avr-gcc. If I do this: int i =
I'm having a really weird problem with my rails app and facebook's open graph

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.