Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Is Excel required on the server?
Message
From
01/05/2006 15:27:50
 
 
To
01/05/2006 15:08:27
Keith Payne
Technical Marketing Solutions
Florida, United States
General information
Forum:
ASP.NET
Category:
Other
Miscellaneous
Thread ID:
01117194
Message ID:
01118158
Views:
25
Here is another one I found using XLS translation:
Namespace ExcelUtil

    Public Class WorkbookEngine

        ' you could have other overloads if you want to get creative...
        Public Shared Function CreateWorkbook(ByVal ds As DataSet) As String
            Dim xmlDataDoc As New XmlDataDocument(ds)
            Dim xt As New XslTransform()
            Dim reader As New StreamReader(GetType(WorkbookEngine).Assembly.GetManifestResourceStream(GetType(WorkbookEngine), "Excel.xsl"))
            Throw New System.Exception("5")
            Dim xRdr As New XmlTextReader(reader)
            xt.Load(xRdr, Nothing, Nothing)
            Dim sw As New StringWriter()
            xt.Transform(xmlDataDoc, Nothing, sw, Nothing)
            Return sw.ToString()
        End Function 'CreateWorkbook
    End Class 'WorkbookEngine

End Namespace 'ExcelUtil
This one reads a dataset and works with it to obtain an XML ready to be read by Excel. However, I cannot proceed on the assembly line. I end up with:

Value cannot be null.
Parameter name: stream
Michel Fournier
Level Extreme Inc.
Designer, architect, owner of the Level Extreme Platform
Subscribe to the site at https://www.levelextreme.com/Home/DataEntry?Activator=55&NoStore=303
Subscription benefits https://www.levelextreme.com/Home/ViewPage?Activator=7&ID=52
Previous
Reply
Map
View

Click here to load this message in the networking platform