How can I send 'Save' message to the excel main window?

G

Guest

Hi,

I'm developing windows application using VB.Net 2005.
I would like to send 'save' message using 'SendMessage' API to the excel
appication. I've already got a handle of the excel window with 'FindWindow'
API.
How can I send 'save' command to external excel window?

Actual thing I want to do is I can handle excel application in the winform.
My client hope that all staff can use excel application in new window
application.
So, I placed excel application to the panel control on the winform using
'SetParent' API.
But I've found that excel application's main window handle is changed after
placing in the winform. So, I couldn't do anything with original excel main
window handle.

Finally, I'm trying to find another way.
First way is that user click 'open' button on the window application to open
an excel file in the network folder, and start excel application, and user
update excel file on the external excel application, and then click 'save'
button on the window application to save external excel file, and click
'close' button on the window application to close external excel application.

So, I need to use 'SendMessage' API to save and close excel application.
How can I do?

Second way is using 'Process' namespace.
However, to use 'Process' I have to study more and more.
Can you help me?

Thank you for your time.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top