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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 29, 20262026-05-29T20:15:12+00:00 2026-05-29T20:15:12+00:00

Its mine 3rd day on Titanium SDK. How can I add tab bar in

  • 0

Its mine 3rd day on Titanium SDK.

How can I add tab bar in my window from another .js file ? I mean I have write the code of tab bar in createTabbar.js and I want to add in my firstView.js .

Is it possible ? As I have seen many examples those have written tab bar code in app.js file so…

Thanks…

  • 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-29T20:15:14+00:00Added an answer on May 29, 2026 at 8:15 pm

    Solved :

    I have mainTab.js that holds/returns tab bar.

    mainTab.js :

    CustomTabbar = function makeTab ()
    {
        var tabGroup = Titanium.UI.createTabGroup();
    
        var win1 = Titanium.UI.createWindow
        ({  
            url:'TabClasses/Tab1/Tab1.js',
            navBarHidden:false,   
            title:'List 1'                 
        });
    
        var tab1 = Titanium.UI.createTab
        ({  
              icon:'KS_nav_views.png',
              window:win1
        });
    
        // create controls tab and root window
        var win2 = Titanium.UI.createWindow
        ({        
            url:'TabClasses/Tab2/Tab2.js',
            navBarHidden:false,
            title:'List 2'
        });
    
        var tab2 = Titanium.UI.createTab
        ({  
            icon:'KS_nav_ui.png',
            window:win2
        });
    
        // create controls tab and root window
        var win3 = Titanium.UI.createWindow
        ({            
            url:'TabClasses/Tab3/Tab3.js',
            navBarHidden:false,
            title:'List 3'
        });
    
        var tab3 = Titanium.UI.createTab
        ({  
            icon:'KS_nav_ui.png',
            window:win3
        });
    
        // create controls tab and root window
        var win4 = Titanium.UI.createWindow
        ({           
            url:'TabClasses/Tab4/Tab4.js',
            navBarHidden:false
        });
    
        var tab4 = Titanium.UI.createTab
        ({  
            icon:'KS_nav_ui.png',
            window:win4
        });
    
        //  add tabs
        tabGroup.addTab(tab1);
        tabGroup.addTab(tab2);
        tabGroup.addTab(tab3);
        tabGroup.addTab(tab4);
    
        tabGroup.open
        ({          
            transition: Titanium.UI.iPhone && Titanium.UI.iPhone.AnimationStyle.NONE
        });
    
        return tabGroup ;
    }
    

    Now in my login.js file I called mainTab.js like :

    Ti.include("mainTab.js");
    
    loginBtn.addEventListener('click',function(e)
    {
         if (loginSuccess)
         {
            win.close();
            var tabs = CustomTabbar();
         } 
    }
    

    As I am new to Titanium, if there is some better approach to do the same, please suggest me…

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

Sidebar

Related Questions

Its mine 2nd day on Titanium SDK. I want to show multiple annotations on
Got some code that is not mine and its producing this warning atm: iehtmlwin.cpp(264)
I was talking with a programmer pal of mine about inheritance and its use
Its possible I am just really really thick. However, looking over the SDK for
a collegue of mine proposed to me an exercise from an online judge website,
I'm trying to use Twitter Bootstrap's dropdown menu in its top nav bar. You
I recently put a django project of mine into its beta stages and would
This next challenge of mine involves jqtransform which can be found here http://www.dfc-e.com/metiers/multimedia/opensource/jqtransform/ I
The reply to a recent question of mine indicated that an actor processed its
When answering a comment to another answer of mine here , I found what

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.