Click here to Skip to main content
13,346,882 members (35,722 online)
Click here to Skip to main content
Add your own
alternative version

Tagged as


1 bookmarked
Posted 8 Sep 2011

Closing all panes in an AJAX Accordion

, 8 Sep 2011
Rate this:
Please Sign up or sign in to vote.
How to close all panes in an AJAX Accordion.

Recently I faced a problem in making all panes of the Accordion control close by default, and I spent many hours searching until I discovered a solution by myself. And here is what we should do:

In the Accordion control, set requireopenedpane to false and selectedindex="-1".

It will work like magic. Good luck.


This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


About the Author

mhamad zarif
Software Developer Netiks
Lebanon Lebanon
I have been a programmer for about one year.My power is in and flash (actionscript 3).I also work on windows application using and c#.

You may also be interested in...

Comments and Discussions

GeneralMy vote of 1 Pin
Member 1099308324-Sep-14 7:50
memberMember 1099308324-Sep-14 7:50 
Questionnot working Pin
irfanansari23-Apr-14 10:12
groupirfanansari23-Apr-14 10:12 
Generalthank u Pin
Mohammad Aboush1-Oct-13 14:12
memberMohammad Aboush1-Oct-13 14:12 
QuestionYes......... Pin
rhubka14-Mar-13 10:50
memberrhubka14-Mar-13 10:50 
GeneralReason for my vote of 5 sdf Pin
nilaypatel929-Jan-12 19:37
membernilaypatel929-Jan-12 19:37 
Generaldfgdgfdg Pin
Kaialsh Chandra Behera10-Nov-11 3:06
memberKaialsh Chandra Behera10-Nov-11 3:06 
Generalgfdg Pin
Kaialsh Chandra Behera10-Nov-11 3:06
memberKaialsh Chandra Behera10-Nov-11 3:06 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.

Permalink | Advertise | Privacy | Terms of Use | Mobile
Web04 | 2.8.180111.1 | Last Updated 8 Sep 2011
Article Copyright 2011 by mhamad zarif
Everything else Copyright © CodeProject, 1999-2018
Layout: fixed | fluid