-
7 Nov 2011 9:27 PM #1
Unanswered: Expand particular accordion panel based on onclick event
Unanswered: Expand particular accordion panel based on onclick event
Hi all,
I want to expand particular accordion panel based on onclick event ..
can u guys help me out how to achieve this?
-
8 Nov 2011 10:12 AM #2Sencha - Senior Forum Manager
- Join Date
- Mar 2007
- Location
- St. Louis, MO
- Posts
- 33,641
- Vote Rating
- 434
- Answers
- 3106
Can you get the panel you want to expand?
Mitchell Simoens @SenchaMitch
Sencha Inc, Senior Forum Manager
________________
http://www.JSONPLint.com - Source to lint your JSONP!
Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
https://github.com/mitchellsimoens
Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/
Need more help with your app? Hire Sencha Services services@sencha.com
Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is almost in print!
When posting code, please use BBCode's CODE tags.
-
8 Nov 2011 10:19 AM #3
Code:items: [ { title: 'A-E', id:'A-E', layout:'fit', collapsed: true }, //Ext.getCmp('A-E').collapse();//
-
8 Nov 2011 10:25 AM #4Sencha - Senior Forum Manager
- Join Date
- Mar 2007
- Location
- St. Louis, MO
- Posts
- 33,641
- Vote Rating
- 434
- Answers
- 3106
- Try not to set static ids
- You should be able to use expand/collapse on the child items. Just tested with 4.0.7 and it works.
Mitchell Simoens @SenchaMitch
Sencha Inc, Senior Forum Manager
________________
http://www.JSONPLint.com - Source to lint your JSONP!
Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
https://github.com/mitchellsimoens
Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/
Need more help with your app? Hire Sencha Services services@sencha.com
Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is almost in print!
When posting code, please use BBCode's CODE tags.
-
8 Nov 2011 10:26 AM #5
try this
Code:title:'aaa', id:'devpanel', bodyStyle:'padding:10px', html:'bbb' },{ /////adding an event listener to a ahref tag Ext.EventManager.addListener("devsnippets", 'click', function(){ Ext.getCmp('devpanel').expand(); }, this, { preventDefault: true } );/// <a href="#" id="devsnippets">expand</a>


Reply With Quote
my ext js site