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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T17:40:32+00:00 2026-05-31T17:40:32+00:00

If I write directly something like this in implementation file: UINavigationBar *navBar = [[UINavigationBar

  • 0

If I write directly something like this in implementation file:

UINavigationBar *navBar = [[UINavigationBar alloc] init];

In this case I haven’t set any property to my navBar, what will be its property/properties/nothing.

EDIT

-(IBAction) loginButtonPressed:(UIButton *)sender
{
UITabBarController *tabBar = [[UITabBarController alloc] init];
FirstScreen *f = [[FirstScreen alloc] initWithNibName:@"FirstScreen" bundle:nil];
UINavigationController *nav1 = [[UINavigationController alloc] initWithRootViewController:f];
nav1.title = @"FirstScreen";

SecondScreen *s = [[SecondScreen alloc] initWithNibName:@"SecondScreen" bundle:nil];
UINavigationController *nav2 = [[UINavigationController alloc] initWithRootViewController:s];
nav2.title = @"SecondScreen";

ThirdScreen *t = [[ThirdScreen alloc] initWithNibName:@"ThirdScreen" bundle:nil];
UINavigationController *nav3 = [[UINavigationController alloc] initWithRootViewController:t];
nav3.title = @"ThirdScreen";

NSArray *navControllers = [NSArray arrayWithObjects:f, s, t, nil];

tabBar.viewControllers = navControllers;

}
  • 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-31T17:40:33+00:00Added an answer on May 31, 2026 at 5:40 pm

    The properties of an object default to nil, or 0. But it is possible that these values have been changed in the init method.

    For more information, you can always consult the documentation:

    • tintColor : The default value is nil.

    • barStyle : The default value is UIBarStyleDefault.


    Edit

    To answer your edited question, tabBar, nav2, … are local variables and not properties.

    If you want them to be properties, you have first to declare such properties then, you have to access using self.tabBar, …

    In the .h file:

    // ...
    @property (strong, nonatomic) UITabBarController *tabBar;
    // ...
    

    And in the .m file:

    // ... @synthesize tabBar;
    
    -(IBAction) loginButtonPressed:(UIButton *)sender
    {
        self.tabBar = [[UITabBarController alloc] init];
        // ...
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

To set validation inside a Model in Rails, I should write something like: class
I want to write a query that does something like this SQL query: SELECT
I want to write some text directly to a file using Flex 3 /
In the documentation of ASP.NET MVC says that you should do something like this
Possible Duplicate: JavaScript Pass Variables Through Reference How can you do something like this
If I put a control in a .aspx file like this; <asp:TextBox ID=protectedTextBox runat=server>Some
I'm trying to build an object that looks something like this: public class MyObject
I've got a windows batch file, with a few sub-routines in it something like
I need to pull something like this off: foo.user$ ffmpeg -i -y foo.mediafile -ss
I have a table looking something like this: +-------+-----+ |country|prop1| +-------+-----+ |RO | 1

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.