Jun 17, 2009, 10:01 PM
[CLOSED] Finding a menu with Ext.getCmp()
If I add a menu to the page (in code behind) with something like this
Cool.Menu myMenu = new Cool.Menu();
myMenu.ID = "myMenuID";
myMenu.Items.Add (...)
What gets rendered is something like this:this.myMenuId = new Ext.menu.Menu({
proxyId: "myMenuId",
items: [new Ext.menu.Item({ ... })] });
But when I try and find the menu by id with the following code, I can't find it var myMenu = Ext.getCmp('myMenuId');
I assume this is because the menu is rendered (for some reason) with a proxyId rather than just an Id.How can I find a menu using the Ext.getCmp() function?