Exporting GridView data to Multiple File Formats

  • Thread starter Thread starter feltra
  • Start date Start date
F

feltra

Hi,

The following is from my friend who has only restricted net access
from his office and hence cannot post....

--------------------------------------------------------------------------------------------------
I am trying to export a GridView data to multiple file formats. The
requirement is that when more than one file format is selected and the
"Submit" button is clicked, the data from the grid needs to get
exported to multiple file formats. First of all is it possible? I am
using ASP.NET 2.0 and VS 2005. If possible can you give me any hints
as to how to go about it? Thank you.

Right now I am using the Response.ContentType method to export to the
specified file format. I just change the extension to the file type
that is required (for e.g. For xml, I give .xml and for html I
give .html). I am using a HTMLTextWriter to perform this operation. I
am rendering the GridView control to export the data.

I have been successful to export it to a single file format at one
time. But it does not work when multiple selections are made. Even
then I am able to export in only one format. Can you please help me..?
Thank you.
 
HTTP = 1 Request to 1 Response. If the client browser launches child browser
windows, each can display a file.

--
HTH,

Kevin Spencer
Microsoft MVP

Printing Components, Email Components,
FTP Client Classes, Enhanced Data Controls, much more.
DSI PrintManager, Miradyne Component Libraries:
http://www.miradyne.net
 
Back
Top