Quit Excel Application with OLE

How can I permanently end an excel application using OLE Automation?

I would like to do this in some exception handling so that the excel process doesn't work if the function throws an error.

I am currently using the below code to open excel:

Variant excel = Variant::CreateObject("Excel.Application");

+2
c ++ excel vcl ole c ++ builder


source to share


1 answer


Like this:



OleVariant excel;

excel = Variant::CreateObject("Excel.Application");
//
// Your code
//
excel.OleProcedure("Quit");

      

+3


source to share







All Articles
Loading...
X
Show
Funny
Dev
Pics