Hi
I currently have all my cards defaulted to collapsed.
If the user goes in and manually expands a few cards through out the list.
I like to have a way to callapse them all and vice versa.
If the user has a bunch of cards expanded. I like to beable to expand all the rest of the cards.
Is there a easy and simple way of doing this ? I like to hook this up to two buttons.
Thanks
Allen
Incidentally, when you use this means, the cards do not "know" they've been collapsed.
For example: expand Card 1, hit a "Collapse All" button that iterates through the cards and sets IsContainingCardCollapsed = true, then try to manually re-expand Card 1.
Card 1 still "thinks" it's expanded, so presumably the first click tries to toggle the card to its collapsed state - which it already is - and it takes a second click to expand it.
QUESTION: Is there a way to collapse a card (or all cards) via code, such that the very next click of the expand button will expand it?
Yes, this worked for me.
I loop through each card and set it manually
Thank You
Hello Allen,
Does this approach work for you? Please let me know if you have any further questions or concerns about this matter.
The easiest way to do this is to set the XamDataCards' ViewSettings.ShouldCollapseCards to true or false. However, please note that this will not take in to account any changes in the settings that the user may have made to explicitly set a panel to be collapsed or expanded.
If you want to override what the user has set and make sure all cards are expanded or collapsed at the same time then you'll need to set the collapsed state on all the individual cards to the default. To do this, iterate through all the records and set the Record.IsContainingCardCollapsed property to null.
Please let me know if you have any further questions or concerns about this matter.