View Single Post
  #9   Report Post  
Posted to microsoft.public.dotnet.languages.csharp,microsoft.public.excel.programming,microsoft.public.dotnet.framework.adonet
scorpion53061 scorpion53061 is offline
external usenet poster
 
Posts: 5
Default Create Excel Worksheet in C# / VB

Try this:

http://www.kjmsolutions.com/datasetarray.htm

This will write the dataset to an array and then to an excel spreadsheet.

Also, solutions like these can be found by using the VB.NET/ADO.NET free
search engine tool at
http://www.kjmsolutions.com/newsgrouptool.htm


"Rob Panosh" wrote in
message ...
Horst,

Don't mean to jump on on your thread here but I have a question for you.

Do
you know where I can find documentation for Excel when creating tables

using
ADO.Net? i.e. - datatypes and general syntax ...

Thanks,
Rob Panosh

"Horst Walter" wrote in message
m...
I create an Excel worksheet in C# (should be similar in VB)

Connection String:
"Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" + filename + ";" +
"Extended Properties=Excel 8.0;";

Create string:
"CREATE TABLE S1 (Dt date, St char(40), Cr currency)"

Works fine, but the worksheet is named _S1 (UNDERSCORE!) and not S1.
Why does this happen? Any ideas?

Thx HW