Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: WPF
Hi All
 
Could please suggest me on following ?
 
I am using WPF with VS 4.0 and I have Accrodian Panel there are 5 Item inside it and when I click on Item 1 then other should be closed automatically when I click Item 2 then Item 1 and other item should be closed. means at a time one item should open.
 
Thanks you in Advance.
Posted 17-Dec-12 22:13pm
Comments
Sergey Alexandrovich Kryukov at 18-Dec-12 20:01pm
   
This is not really a question. What's your problem, exactly? What did you try?
—SA
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

Hello
How are the items added to the panel?
Collection to ItemsSource, or manually added in code or XAML?
 
Anyway, there should be possible to loop the items and collaps the other items.
Or if there is some property that handle that in the actual control.
I have never used that panel so I can't give a good answer. But I bet the logic should not be too far away from selected items in a standard ListView or TabPanel.
  Permalink  
Comments
Abhishek Pant at 23-Dec-12 8:06am
   
"I have never used that panel so I can't give a good answer"-funny isn't it :D
theHollow at 25-Dec-12 17:49pm
   
Sorry about that. But I often see that many standard controls share similar behavors and property names etc...often. So that was my point :-) Gave it a shot :-) Hope by the way you found a good solution.
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 2


Accordion in WPF Toolkit
[^]
this tutorial can help you.
Happy Coding Smile | :)
  Permalink  

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



Advertise | Privacy | Mobile
Web03 | 2.8.140709.1 | Last Updated 23 Dec 2012
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid