Show an Excel spreadsheet on a form

  • Thread starter Thread starter BobRoyAce
  • Start date Start date
B

BobRoyAce

I am using Visual Studio 2008 to create a Windows form application.

The application has a form that lists, in a grid at the top of a form,
all of the spreadsheets that the user can view. What I want to do is
make a way, via a button on the form, for the user to open the
selected spreadsheet in the list. However, I'd like to have the
spreadsheet open in a "control" at the bottom of the form. I would
also like to have another button on the form that would allow the user
to do a Save As of the file.

How can I accomplish this?
 
By the way, one thing that I tried was putting a WebBrowser control at
the bottom of the form, and executing the following line of code:

WebBrowser1.Navigate("file://" & _SpreadsheetFolder &
oSpreadsheet.SpreadsheetFilename)

However, what happens is that the user is prompted as to whether they
want to OPEN or SAVE the file. Then, if they click on OPEN, it opens
the file in a completely different window, not within my application.
It also shows a message in the WebBrowser saying "Navigation to the
webpage was canceled" message.
 
I am using Visual Studio 2008 to create a Windows form application.

The application has a form that lists, in a grid at the top of a form,
all of the spreadsheets that the user can view. What I want to do is
make a way, via a button on the form, for the user to open the
selected spreadsheet in the list. However, I'd like to have the
spreadsheet open in a "control" at the bottom of the form. I would
also like to have another button on the form that would allow the user
to do a Save As of the file.

How can I accomplish this?

In the COM world I'd suggest putting an OLE object on your form and hosting
Excel within it. I have no idea how to do it in .NET without using a
specialized control like FarPoint Spread.
 
In the COM world I'd suggest putting an OLE object on your form and hosting
Excel within it. I have no idea how to do it in .NET without using a
specialized control like FarPoint Spread.

So, anyone out there know how this can be done in .NET? Why is
WebBrowser method not working?
 
In the COM world I'd suggest putting an OLE object on your form and hosting
Excel within it. I have no idea how to do it in .NET without using a
specialized control like FarPoint Spread.

So, anyone out there know how this can be done in .NET? Why is
WebBrowser method not working?
 
In the COM world I'd suggest putting an OLE object on your form and hosting
Excel within it. I have no idea how to do it in .NET without using a
specialized control like FarPoint Spread.

So, anyone out there know how this can be done in .NET? Why is
WebBrowser method not working?
 
I was just wondering if you ever found a solution to this problem? I'm running into the same issue developing with VS 2008 trying to embed a word 2007 or excel 2007 document in a VB.Net form. Using IE7, XP-SP3.
 
Back
Top