Re: Export DataSet to Excel

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance

From: MiniMike (MiniMike_at_discussions.microsoft.com)
Date: 03/21/05


Date: Mon, 21 Mar 2005 00:07:01 -0800

Thanks !
Could you give some little more info on how to copy all rows in one go?
Determining the length of the dataset is no problem ...
dataset.tables(0).rows.count should do the trick, doesn't it ...?

"Andibevan" wrote:

> Hi Mike,
>
> If you are able to determine the length (i.e. last row) of your dataset it
> should be faster to copy all of your data rows in one go to excel.
>
> On My PC I am able to run a number of instances of Excel at the same time -
> you may be able to find a way of running two instances of excel. I find
> though that when I am importing text using vba it is safer to leave it until
> it is finished as it seems to take up a lot of processing power.
>
> Sorry if this is a bit vague, but it is just a thought.
>
> Regards
>
> Andi
>
>
> "MiniMike" <MiniMike@discussions.microsoft.com> wrote in message
> news:545F0C2C-8839-4846-B10A-EB24F95DCDDD@microsoft.com...
> > Hi !
> >
> > I'm exporting a .Net dataset to an Excel file, using the Excel Object
> Model.
> > I'm looping through my datarows, adding them one by one to the file.
> >
> > I have 2 questions.
> > * Is there a faster way?
> > * I'm having a problem when i open excel during the loop: the file that is
> > processing in the background, seems to open when i open excel whilst
> looping.
> > Can i avoid this ?
> >
> > Thanks !
>
>
>



Relevant Pages

  • Re: Is it possible to export each row of data to a seperate work book
    ... It just keeps looping. ... Stacey ... "Dick Kusleika" wrote in message ... > Excel Blog - Daily Dose of Excel ...
    (microsoft.public.excel.programming)
  • Re: Need code to copy from "code modules"
    ... See Chip Pearson's page Coding for the VBE ... HTH, ... My Excel Pages: http://www.mvps.org/dmcritchie/excel/excel.htm ... > I am looking for (looping) code to copy the contents of the ...
    (microsoft.public.excel.programming)
  • Export DataSet to Excel
    ... I'm exporting a .Net dataset to an Excel file, ... I'm looping through my datarows, adding them one by one to the file. ... seems to open when i open excel whilst looping. ...
    (microsoft.public.excel.programming)
  • Re: Access Freezes
    ... Your Resource For Help With Access, Excel And Word Applications ... Need a month calendar or 7 day calendar? ... > The subroutine takes some time, ... > I have a progressbar that works while the subroutine is looping. ...
    (comp.databases.ms-access)
  • Re: Export DataSet to Excel
    ... should be faster to copy all of your data rows in one go to excel. ... On My PC I am able to run a number of instances of Excel at the same time - ... > I'm looping through my datarows, adding them one by one to the file. ... seems to open when i open excel whilst ...
    (microsoft.public.excel.programming)