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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T01:31:20+00:00 2026-05-23T01:31:20+00:00

I have a navigation controller that utilizes an if statement to switch between the

  • 0

I have a navigation controller that utilizes an if statement to switch between the different views, and when i run it it comes up with a warning on the line:

ROSS_APP_7AppDelegate *delegate = [[UIApplication sharedApplication] delegate];

warning: type ‘id ‘ does not conform to the ‘UITabBarControllerDelegate’ protocol

I’d like some help on how to get rid of this warning.
Here is the whole if statement:

if(indexPath.row == 0)
{
    MapDetailController *mapD = [[MapDetailController alloc] initWithNibName:@"MapDetailController" bundle:nil];
    self.mapDetailController = mapD;
    [mapD release];

    mapDetailController.title = [NSString stringWithFormat:@"%@", [moreArray objectAtIndex:row]];

    ROSS_APP_7AppDelegate *delegate = [[UIApplication sharedApplication] delegate];
    [delegate.moreNavController pushViewController:mapDetailController animated:YES];


}

Thanks

EDIT:
Here is what my AppDelegate looks like (response to answer #2)

#import <UIKit/UIKit.h>
@class MoreNavController;
@interface ROSS_APP_7AppDelegate : NSObject <UIApplicationDelegate, UITabBarControllerDelegate> {
UIWindow *window;
IBOutlet UITabBarController *tabBarController;
IBOutlet MoreNavController *moreNavController;
}


@property (nonatomic, retain) IBOutlet UIWindow *window;
@property (nonatomic, retain) IBOutlet UITabBarController *tabBarController;
@property (nonatomic, retain) IBOutlet MoreNavController *moreNavController;
@end
  • 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-23T01:31:21+00:00Added an answer on May 23, 2026 at 1:31 am

    You probably forgot to have your app delegate conform to the UITabBarControllerDelegate protocol.

    To implement it, your appDelegate header should look like this (the @interface declaration is the relevant line):

    #import ...
    
    @interface ROSS_APP_7AppDelegate : AppDelegate_Shared <UITabBarControllerDelegate> 
    {
        ....
    }
    
    @property(nonatomic, retain) .....
    
    @end
    

    You might be using AppDelegate_Shared / AppDelegate_iPhone / AppDelegate_iPad so bear in mind that the above example considers a shared app delegate

    EDIT:

    After seeing your comment,

    Try replacing:

    ROSS_APP_7AppDelegate *delegate = [[UIApplication sharedApplication] delegate];
    

    With this:

    ROSS_APP_7AppDelegate *delegate = (ROSS_APP_7AppDelegate*)[[UIApplication sharedApplication] delegate];
    

    Does typecasting the return like this get rid of your warning?

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

Sidebar

Related Questions

I have a navigation controller that displays viewcontroller A. There is a right button
I have an iPhone app that is based on a navigation controller. I have
I have a view with a navigation controller that I am showing modally and
I have a view controller that i'm trying to push onto the navigation stack.
I have a navigation view with a cell that has something as simple as
We have a custom navigation webpart that uses the PortalSiteMapProvider of MOSS to build
Short: Is there a way to have a route-definition that will pass the CONTROLLER/ACTION
I have a navigation controller with a table view. In most tutorials I've read
I have a complicated structure where I have a custom tab-bar controller that houses
I have a fairly simple iPhone application that I want to have run on

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.