Skip to content

Expand/Collapse All Button?

New Discussion
Caleb Whitaker
Caleb Whitaker asked on Oct 11, 2016 2:57 PM

I have Grouping in my Grid and therefore have the little +/- buttons for expanding the groups.

I want to create an Expand/Collapse ALL button. I know how to do this with a regular button outside of the Grid. My questions is, can I put this button INSIDE the Grid?

So maybe like an extra row at the top that holds it or at the far left of the columns. OR even better inside the first column somewhere?

The closest I found to this was on CreationFilters. Would that be the only way to get the button I'm looking for?

Thanks

Sign In to post a reply

Replies

  • 0
    Sahaja Kokkalagadda
    Sahaja Kokkalagadda answered on Oct 10, 2016 10:19 PM

    Hi Caleb,

    Using a CreationFilter is the best way to achieve this. You can refer to the attached sample on how to implement this CreationFilter for displaying an Expand/Collapse All button for the grouped columns in a Grid.

    Please let me know if I may be of further assistance.

    Sincerely,
    Sahaja Kokkalagadda
    Associate Software Developer

    • 0
      Caleb Whitaker
      Caleb Whitaker answered on Oct 11, 2016 2:44 PM

      Ah yes perfect!

      But one last issue. I've tried changing it to a ButtonUIElement rather than a ImageAndTextButtonUIElement because I don't need the image. And now the overridden ButtonClick method is never being called.

      I don't understand why since they both stem from ButtonUIElementBase….

      Any ideas why it randomly stopped being called?

      • 0
        Mike Saltzman
        Mike Saltzman answered on Oct 11, 2016 2:57 PM

        Hi Caleb, 

        I'm not exactly sure why that is, but you could just use OnClick, instead (and don't bother returning a value). 

  • You must be logged in to reply to this topic.
Discussion created by
Favorites
Replies
Created On
Last Post
Discussion created by
Caleb Whitaker
Favorites
0
Replies
3
Created On
Oct 11, 2016
Last Post
9 years, 4 months ago

Suggested Discussions

Tags

Created by

Created on

Oct 11, 2016 2:57 PM

Last activity on

Oct 11, 2016 2:57 PM