Excel Spreadsheet with Infragistics


How can I use Infragistics in Visual Basic.NET to open an a UltraGrid into an Excel spreadsheet?
Who is Participating?
teebonProduct ManagerCommented:
Hi NigelRocks,

Sorry for late reply.
After saving the spreadsheet to a file, you may reopen the spreadsheet in your windows form:

Let me know if it still doesn't work for you.
teebonProduct ManagerCommented:
Hi NigelRocks,

Check this out (there's Visual Basic section):
NigelRocksAuthor Commented:
The code below already looks like what's in the article.  It exports the grid to a file, which is almost what I want.   However, what I'd really like to do is to open an Excel spreadsheet from the app that contains the data in the grid.
Private Sub btnExport_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnExport.Click

            Me.SaveFileDialogExport.Title = "Save Excel File"
            Me.SaveFileDialogExport.Filter = "Excel Spreadsheets (*.xls)|*.xls"

            ' Set the default files type to Excel Spreadsheets
            Me.SaveFileDialogExport.FilterIndex = 1
            ' Set dialog box so an error occurs if the dialogbox is cancelled
            'Me.SaveFileDialogExport. .CancelError = True
            'ben 07/22/09. set a condition to check for the file name is empty or not. 
            If Me.SaveFileDialogExport.FileName <> "" Then
                Me.ugrdAgentsExcelExporter.Export(Me.ugAgents, Me.SaveFileDialogExport.FileName)

            End If

        Catch ex As Exception
            'Throw ex
        End Try
    End Sub

Open in new window

Cloud Class® Course: CompTIA Cloud+

The CompTIA Cloud+ Basic training course will teach you about cloud concepts and models, data storage, networking, and network infrastructure.

teebonProduct ManagerCommented:
Hi NigelRocks,

Do you mean that you want to open Excel spreadsheet in the web browser OR you want MS Excel to be launched and open the spreadsheet?
NigelRocksAuthor Commented:
This is in Windows Forms.  And yes, I'd like the data in the graph to be opened in an Excel spreadsheet.
teebonProduct ManagerCommented:
I'm providing a solution.
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.