Question

I have a Ext Js panel and I want to get the Title of the panel for some purpose.

I have the id of the panel and I need to get the title of the panel from it.

I am looking for some thing like this

Ext.getCmp('myPanel').getTitle();

I am using Ext Js 3.4

Was it helpful?

Solution

Since no getTitle() method is defined for the component Ext.Panel, I would go for the property directly:

var myTitle = Ext.getCmp('myPanel').title;
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top