ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Embedding Excel in a C# WinForm (https://www.excelbanter.com/excel-programming/380586-re-embedding-excel-c-winform.html)

NickHK

Embedding Excel in a C# WinForm
 
Tracy,
Here's how to do it in VB:
http://abstractvb.com/code.asp?A=959

Not in a web browser though.

NickHK

"Tracy" wrote in message
...
I'm attempting to embed Excel in a C# WinForm using the information

contained
he http://support.microsoft.com/kb/304662/EN-US/. It works well unless
Excel is already running in its own window. In this case, the embedded

Excel
causes the already running Excel to close its workbook and freeze up. This
happens because the running instance is reassigned (or perhaps reparented)

to
the WinForm.

Is it possible to force a new Excel.exe to be created that serves just the
instance embedded on the WinForm?




NickHK

Embedding Excel in a C# WinForm
 
Tracy,
In VB, you get an instance of Excel that can do anything.
You need to check if C# requires extra work.

NickHK

"Tracy" wrote in message
...
That approach works great for displaying data but not for editing since

all
keystrokes are ignored.

Tracy

"NickHK" wrote:

Tracy,
Here's how to do it in VB:
http://abstractvb.com/code.asp?A=959

Not in a web browser though.

NickHK






All times are GMT +1. The time now is 09:00 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com