Quantcast
Channel: DevExpress Support Center (Examples)
Viewing all articles
Browse latest Browse all 7205

How to export GridView data to different text formats

$
0
0

This example is standalone implementation of the online Grid View - Exporting Data demo.
It illustrates how to export the GridView 's content to several rich text formats via the ExportTo*** methods.

This example is an illustration of the KA18639: How to export GridView rows and keep end-user modifications (such as sorting, grouping, filtering, selection) KB Article. Refer to the Article for an explanation.

Please note the following key moments:
- The GridView Extension should be defined via a separate PartialView without any additional tags (see the Using Callbacks help topic for more information);
- The GridView's PartialView should be wrapped within a form in order to apply the client layout state (sorting, filtering, etc.);
- An export trigger should submit this form to the corresponding Controller Action (i.e., make a POST request);
- The GridViewSettings (especially the Name property) should be the same in PartialView and Controller;
- The datasouce/Model should be the same in PartialView and Controller.

Question Comments

Added By: Nurhak Kaya at: 9/4/2012 7:58:55 AM    

Really good! Thanks a lot!

Added By: Steven Jansick at: 7/11/2014 11:44:57 AM    

Does this work when binding with BindToCustomData?

I have verified that all of the Conditions have been met but when I export, it is not maintaining the Grouping Order.  Do you have any recommendations?

Added By: Mike (DevExpress Support) at: 7/14/2014 12:05:58 AM    

Hello,

To process your recent post more efficiently, we copied it to a separate ticket created on your behalf: T128968: GridView - Export Data when using BindToCustomData method.
This ticket is currently in our processing queue. We will post to it as soon as we have any updates.


Viewing all articles
Browse latest Browse all 7205

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>