We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Exporting To Excel from Grid data bound control

Thread ID:





55207 Jan 25,2007 04:07 AM UTC Jan 25,2007 12:26 PM UTC WinForms 1
Tags: XlsIO
Anna Srinivasan
Asked On January 25, 2007 04:07 AM UTC

Please find attached images for "Exporting To Excel from Grid data bound control".
I am using the following syncfusion method to export.
"sheet.ImportDataView(dtExport.DefaultView, true, 4,1, maxRows, -1, false);"
Please look at the comments column (String column) in the image, I am having this (05/08 2 5/8) value on comments column first row and my data table also contains the same value, but when I do export, it is coming like (05/08/2007) instead of (05/08 2 5/8).
Kindly give me the solution at the earliest.



Melba Winshia [Syncfusion]
Replied On January 25, 2007 12:26 PM UTC

Hi Anna,

Could you please set "true" to the preserveTypes property of ImportDataView method so that the data type is also preserved along with it during importing into excel? Please refer the following code snippet that illustrates the above:

//Import data to excel

Please refer the following sample which implements the above said feature:


Please take a look at the attached sample and let me know if you have any other queries.

Best Regards,


This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon