PC Review


Reply
Thread Tools Rate Thread

ADO.NET with Excel 2003

 
 
Andre Grumbach
Guest
Posts: n/a
 
      28th Jan 2010
Hi all,
I try to generate a little application to export Data to an excel sheet.

First it looks really nice, because it's write the data to the excel sheet.

But now I have following problem:
I try to write the data to different Cells, e.g. write the first name in
Cell B4, the last name to B5 an so on. The excel I use for this export is
completely empty. So there are no cells initialize.

When I write in cell B4 all the time I get the Error:
The tables contains cells, which are outside the defined Array. (or some
similar, it's an german system [Die Tabelle enthält Zellen, die sich
außerhalb des definierten Bereichs befinden.])

If I write first manual data in cell A4 and A5 there is no problem.
But I could initialize all cells manual, because, it should be an excel
sheet with different pages and a lot of cells and rows.

Is there any way to initialize the cells automatic on insert into the sheet?

Here my query:
Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" + fileName + ";Extended
Properties=\"Excel 8.0;HDR=YES;\""

SELECT * FROM [Tabelle1$A15:B16]
INSERT INTO [Tabelle1$A15:B16] VALUES ('AG', 'EG')

Thanks,
Andre

 
Reply With Quote
 
 
 
 
Miro
Guest
Posts: n/a
 
      29th Jan 2010
You may want to have a look here.

****But this requires office2007 format.
Not the 2003 you are trying to do.

It allows you to create an xmlfile to create the spreadsheet.
http://www.vb-tips.com/dbpages.aspx?Search=excel

Miro

"Andre Grumbach" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> Hi all,
> I try to generate a little application to export Data to an excel sheet.
>
> First it looks really nice, because it's write the data to the excel
> sheet.
>
> But now I have following problem:
> I try to write the data to different Cells, e.g. write the first name in
> Cell B4, the last name to B5 an so on. The excel I use for this export is
> completely empty. So there are no cells initialize.
>
> When I write in cell B4 all the time I get the Error:
> The tables contains cells, which are outside the defined Array. (or some
> similar, it's an german system [Die Tabelle enthält Zellen, die sich
> außerhalb des definierten Bereichs befinden.])
>
> If I write first manual data in cell A4 and A5 there is no problem.
> But I could initialize all cells manual, because, it should be an excel
> sheet with different pages and a lot of cells and rows.
>
> Is there any way to initialize the cells automatic on insert into the
> sheet?
>
> Here my query:
> Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" + fileName + ";Extended
> Properties=\"Excel 8.0;HDR=YES;\""
>
> SELECT * FROM [Tabelle1$A15:B16]
> INSERT INTO [Tabelle1$A15:B16] VALUES ('AG', 'EG')
>
> Thanks,
> Andre
>


 
Reply With Quote
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Excel 2007 versus Excel 2003 & Excel 97-2003 fully compatible Bumpersnesty Microsoft Excel Worksheet Functions 0 26th Apr 2010 09:44 PM
Excel 2003 help doesn't work. I got both Excel 2003 and 2007 insta Kenneth Andersen Microsoft Excel Misc 0 16th Feb 2010 10:44 AM
Can't open Excel 2007 files saved as 2003 in Excel 2003 Laura Microsoft Excel Crashes 1 13th Nov 2008 06:44 PM
Excel 2007 crashed after saving excel 2003 file into 2003 format kpy Microsoft Excel Crashes 0 17th Jun 2008 08:53 AM
Word 2003 Find/Change Automation from Excel 2003 crashes Excel 200 =?Utf-8?B?Sm9lbCBCZXJyeQ==?= Microsoft Excel Programming 9 6th Mar 2006 10:20 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 05:33 AM.