View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Fredrik Wahlgren Fredrik Wahlgren is offline
external usenet poster
 
Posts: 339
Default Open XML string in Excel using C#


"Stefani" wrote in message
...
Hello,

I am using the code below to programmatically create an .xls file:
Excel.Workbook newWorkbook =
excelApp.Workbooks.Add(XlWBATemplate.xlWBATWorkshe et);

I have an XML string of data that I'd like to just "shove" into the .xls
then open Excel. The XML string is a result of an SQL query. The User

will
then use Excel view and manipulate the data.
I've found no API documentation to do this en masse and not cell by cell.

Thanks in advance,

Stefani


Save the xml string to a file with an xml extension. Excel can open xml
files. I think you need at least Excel 2002.

/Fredrik