What can OWC11 do?

D

Dale

I am building an application with ASP.NET/C# that enables a user to upload an
excel file. Then, the app queries the file via ODBC and loads the contents
into a dataset. Next the contents of the dataset are sent to a SQL stored
procedure in XML format. The stored procedure loads the data into the
database.

The query that extracts the data from the excel file looks like this:
“SELECT * FROM [sheet1$]â€. My problem is that I don’t always know what the
name of the sheet is.

Is there a way with OWC11 that I can open the Excel file and discover the
name of the first worksheet?

Is it possible to simply create a dataset or an XML file with OWC11 rather
than hitting the file with ODBC?

Finally, can I use OWC11 to interact with the Excel file without installing
Excel on the server?

Thanks for your help.
 
P

Peter Huang

Hi Dale,

Now we are researching the issue and we will update you with new
information ASAP.

Best regards,

Peter Huang
Microsoft Online Partner Support

Get Secure! - www.microsoft.com/security
This posting is provided "AS IS" with no warranties, and confers no rights.
 
W

Wei-Dong XU [MSFT]

Hi ,

1. OWC11 can't read the excel file directly. However, you can save the
excel file as xml format and then SpreadSheet control of OWC11 can read
the xml data. To obtain the worksheet name, you will need to use the Excel
Object model to do, for example:
Sub ObtainName()
Dim ws As Worksheet
Application.Workbooks.Open "c:\test.xls"
For Each ws In ThisWorkbook.Worksheets
Debug.Print ws.Name
Next
End Sub

2. As I know, from SpreadSheet control of OWC11 you can save the data as
xml format file. Perhaps this can help you some regarding this issue.

3. You will need to install Excel in the client box so that OWC can
interact with excel, for example open the file in Excel etc.

Please feel free to let me know if you have any question.

Best Regards,
Wei-Dong Xu
Microsoft Product Support Services
Get Secure! - www.microsoft.com/security
This posting is provided "AS IS" with no warranties, and confers no rights.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top