This is a migrated thread and some comments may be shown as answers.

Column chooser

8 Answers 314 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Marco
Top achievements
Rank 1
Marco asked on 25 Sep 2009, 02:46 AM
Hello,
Is there a way to show/hide columns in runtime?  I can think of a way to display the list of columns in a popup window and then toggle on/off the visibility of the columns.  What would be the recommended way to achieve this?  A code snipped will be appreciated

Thanks in advance,
Marco

8 Answers, 1 is accepted

Sort by
0
Accepted
Vlad
Telerik team
answered on 25 Sep 2009, 06:00 AM
Hi Marco,

Please check this blog post for more info:
http://blogs.telerik.com/vladimirenchev/posts/09-04-10/how_to_custom_header_context_menu_with_radgridview_for_silverlight.aspx

The same approach will be the same however you will need to use standard ContextMenu instead (no RadContextMenu for WPF).

Kind regards,
Vlad
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
0
Shunmuga Priya K
Top achievements
Rank 1
answered on 13 Jan 2012, 09:29 AM
Hello,
Is there a way to show/hide columns using context menu instead of popup window as in the example attached "columnchooser-wpf.zip" in the link http://www.telerik.com/community/forums/wpf/gridview/use-context-menu-to-show-and-hide-columns.aspx ? I can think of a way to display the list of columns in a context menu and then toggle on/off the visibility of the columns in the button("column chooser"). A code snipped will be appreciated

Thanks in advance,
Priya
0
Vlad
Telerik team
answered on 13 Jan 2012, 09:47 AM
Hi,

You can  check  this demo for more info. The same is available in your local copy of our WPF examples. 

Kind regards,
Vlad
the Telerik team

Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

0
Shunmuga Priya K
Top achievements
Rank 1
answered on 13 Jan 2012, 09:53 AM
Hi,

Thanks for the quick reply.I can see in the link the demo for a gridview.But it contains context menu in right click of grid header.But i need
 show/hide columns using context menu instead of popup window as in the example attached "columnchooser-wpf.zip" in the link http://www.telerik.com/community/forums/wpf/gridview/use-context-menu-to-show-and-hide-columns.aspx. I can think of a way to display the list of columns in a context menu and then toggle on/off the visibility of the columns in the button("column chooser") as in the example attached "columnchooser-wpf.zip" in the link http://www.telerik.com/community/forums/wpf/gridview/use-context-menu-to-show-and-hide-columns.aspx.

Thanks in advance,
Priya
0
Shunmuga Priya K
Top achievements
Rank 1
answered on 13 Jan 2012, 11:44 AM
Hi,

In the demo (this demo), is the context menu for the column chooser invoked explicitly in the header row or is it a implicit invocation?

Thanks,
Priya
0
Shunmuga Priya K
Top achievements
Rank 1
answered on 13 Jan 2012, 12:39 PM
On a button click, is it possible to invoke a telerik datagrid column chooser context menu?
0
Mauro
Top achievements
Rank 1
answered on 05 Jul 2013, 11:20 AM
Is possible to use such Listbox to reorder with drag & drop the order of the columns too?

Thx in advance
Mauro
0
Dimitrina
Telerik team
answered on 05 Jul 2013, 12:58 PM
Hi Mauro,

You can use the drag and drop to reorder the items in the list. Then you should assure that the DispayIndexes for the columns correspond to the order indexes in the list. 

Regards,
Didie
Telerik
TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for WPF.
Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
Sign up for Free application insights >>
Tags
GridView
Asked by
Marco
Top achievements
Rank 1
Answers by
Vlad
Telerik team
Shunmuga Priya K
Top achievements
Rank 1
Mauro
Top achievements
Rank 1
Dimitrina
Telerik team
Share this question
or