Wrox Programmer Forums
|
ASP.NET 2.0 Professional If you are an experienced ASP.NET programmer, this is the forum for your 2.0 questions. Please also see the Visual Web Developer 2005 forum.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 2.0 Professional section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old August 6th, 2007, 05:15 AM
Authorized User
 
Join Date: Sep 2006
Posts: 23
Thanks: 0
Thanked 0 Times in 0 Posts
Default Another problem

Hi Planoie,

What i generally do to export data to excel
1. populate a dataset
2. bind it to datagrid/Repeater/Gridview/Datatable
3. Export it to Excel

Is there any other way to export directly from a dataset so that i can rearrange the columns to display.

Thanks in advance


 
Old August 6th, 2007, 10:21 AM
planoie's Avatar
Friend of Wrox
 
Join Date: Aug 2003
Posts: 5,407
Thanks: 0
Thanked 16 Times in 16 Posts
Default

Given that you are exporting from a web app you aren't going to be able to do very much after you export. (If you were in a desktop app then you could potentially interact with Excel directly.)

However, you can rearrange the dataset columns as you like before you export. I would think that would be the easiest way.

-Peter









Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.