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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T03:20:49+00:00 2026-06-11T03:20:49+00:00

Here my app.js code : Ext.Loader.setConfig({ enabled: true }); Ext.application({ name: ‘KP’, appFolder: ‘scripts/app’,

  • 0

Here my app.js code :

Ext.Loader.setConfig({
    enabled: true
});

Ext.application({
    name: 'KP',
    appFolder: 'scripts/app',

    controllers: [
        'login.Login'
    ],

    views: [
        'login.Login'
    ],


    launch: function () {

        var view = Ext.widget('login')
    }


});

If I want to use some others views, controllers, models and stores in my application, should I define them in app.js? (like this : controllers[….all of my controllers…..])
Are there other way to get to work init function in my controllers? 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-06-11T03:20:50+00:00Added an answer on June 11, 2026 at 3:20 am

    There are many ways…

    Following some basics first:

    All controllers that are listed within the controllers array of the application controller get instantiated at startup (application get initialized with the onReady event. Also the init() and onLaunch() methods of the listed controllers get called. See the linked API for details when this occurs). Now each instantiated controller initialize its stores,views and models (creates getter for all and over that creates instances of each store while overwriting the storeId and append them to the Ext.StoreMgr). Note that each controller will contains his own models, stores and views.

    The simplest way to receive a controller that is not listed in the application controller is by using a reference of the application controller and calling getController(name)

    It is Important to know that while using that way the receive a controller instance the getter method will not call the init() or onLaunch() method for the invoked controller, it will just try to get the controller or create it. You should also note the API for those methods in these controllers are no longer correct. You need to set an init bool to these controllers and check it on the reference that the getController(name) method hands back to you. If it is undefined/false you call the init() / onLaunch() by yourself and set it after that. I use these technique by myself to reduce intial load for bigger application. I guess you don’t really need this for just a handful of controllers.

    Update

    Due to some changes in the 4.1.x release it is no longer required to init the controller
    manually. This is now done for us by the getController method

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

Sidebar

Related Questions

Here's my App code: Ext.application({ name: 'ProjectName', appFolder: APP_URL + app, // phoneStartupScreen: 'LOGO.png',
i've a jquery (UI) App here where the whole JQuery Code gets a little
Here's the error code: The app you are using is not responding. Please try
Here is my code (seen on Google App Engine) public void doGet(HttpServletRequest request, HttpServletResponse
Here is my code stub for my app-delegate.m -- it never gets called. -
Here is my code import org.ksoap2.*; import org.ksoap2.serialization.*; import org.ksoap2.transport.*; import android.app.Activity; import android.os.Bundle;
Here is an Example of the app. The essential code is in: golang-code/handler/handler.go (After
Here's the line from App.Config: <add key=CheckFileFormatString value=P{0}\t&quot;{1}, {2}&quot;\t{3}\t{4}\t{5}\t{6}\t{7}\t{8}\t{9}\t{10}/> Here's the code that puts
My app crashed when i trying to change UITextView text. Here is the code:
Some clients experience an app crash directly when they launch it. Here's the code

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.