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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T05:39:15+00:00 2026-05-24T05:39:15+00:00

I am using the following code in my application as an xtype. My list

  • 0

I am using the following code in my application as an xtype. My list item is appearing the way i want but when i click on an item i have this error everytime i click on an item that is supposed to load a new page with datas : Uncaught TypeError: Object function (){h.apply(this,arguments)} has no method ‘setActiveItem’. Any idea of how can i fix it? The refered items lines are commented in the code.

Here is my code :

var AppsBack = new Ext.Toolbar({
dock: 'top',
items: [{
    text: 'back',
    ui: 'back',
    handler: function(){
        Home.setActiveItem('home'); //Here is the second problem
    }
}]
});

var AppsDetails = new Ext.Panel({
id: "appsdetails",
tpl: "{game}",
dockedItems: [AppsBack]
});

var AppsList = new Ext.List({
id: "appslist",
store: AppsStore,
layout: 'card',
emptyText: "No game found",
itemTpl: "{game}",
listeners: {
    itemtap: function(view, index, item, e) {
        var rec = view.getStore().getAt(index);
        AppsDetails.update(rec.data);
        AppsBack.setTitle(rec.data.game);
        Home.setActiveItem('appsdetails') //Here is the first problem
    }
}
});

var AppsListWrapper = new Ext.Panel({
id: "appslistwrapper",
layout: 'card',
items: [AppsList],
dockedItems: []
});

var Home = Ext.extend(Ext.Panel, {
id: "home",
iconCls: 'home', 
title: 'Home',
fullscreen: true,
layout: 'card',
cardSwitchAnimation: 'slide',

initComponent: function() {
    Ext.apply(this, {
        items: [AppsListWrapper, AppsDetails]
    });
    Home.superclass.initComponent.apply(this,arguments)
}
});
Ext.reg('appsList', Home);

Thanks for your help


After a couple manipulation, i’ve discovered that the only reason why i am experiencing this trouble is because i am trying to extend the panel. In other terms if i use
new Ext.Panel
intead of
Ext.extend(Ext.Panel, {…
everything works fine excepted i can’t use xtype in this case. Any ideas?

  • 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-24T05:39:15+00:00Added an answer on May 24, 2026 at 5:39 am

    I figured it out!!!
    MY solution consists in giving the new extended class as few arguments as possible. Therefore i divided the home extended class into two objects like this :

    var Home = new Ext.Panel({
    id: "home",
    layout: 'card',
    cardSwitchAnimation: 'slide',
    items: [AppsListWrapper, AppsDetails]
    });
    
    var HomeTab = Ext.extend(Ext.Panel, {
    iconCls: 'home',
    title: 'Home',
    layout: 'card',
    initComponent: function() {
        Ext.apply(this,{
            items: [Home]
        }); 
        HomeTab.superclass.initComponent.apply(this,arguments);
    }
    });
    Ext.reg('home', HomeTab);
    

    Don’t ask me how come, i won’t be able to answer. I just followed my intuition 😉

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

Sidebar

Related Questions

I'm using following code but cannot return data from MySQL. This is the output:
all! I want to create multiple threads in my application. I' using following code
I'm using following code to open URL on a button click from application: [[UIApplication
I am Using Following Code for Send the Email from my application but problem
I'm using the following code within a VB 6.0 application to allow give the
Using the following code, I'm retrieving a list of Integers from a DB and
I am sending file using following code in my android application : Intent intent
I'm using following code to open the web.config of my current web application. Configuration
In my application I m using following code below:- NSArray* toolbarItems = [NSArray arrayWithObjects:
I am using following code in my application to read the string value from

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.