[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

microsoft.public.dotnet.framework.interop

how to quit excel wihtout saving

GS

6/16/2007 9:29:00 PM

how to quit excel without saving and suppress the prompt?

I am suing excel application for some intermediate work but don't want to
save the result in excel


2 Answers

SvenC

6/18/2007 11:44:00 AM

0

Hi,

> how to quit excel without saving and suppress the prompt?
>
> I am suing excel application for some intermediate work but don't
> want to save the result in excel

Set the Saved property of all open Workbooks to True.

--
SvenC

GS

6/18/2007 9:53:00 PM

0

thank you very much,
I guess the key is **all** the work books. I only marked the workbooks I
added

thank you

btw I resort to
oBook.Saved = True ' not needed if xlApp_WorkbookBeforeClose is in
place


oExcel.PromptForSummaryInfo = False
oExcel.Application.DisplayAlerts = False
to avoid being prompting

I suspect I still missed a workbook someplace "the only workbook I can find
is actually in the line
oExcel.Workbooks.Add
but that dos not have the property Saved for oExec.Workbooks.


"SvenC" <SvenC@community.nospam> wrote in message
news:9536B506-F243-44BC-9389-BB0B201D0D57@microsoft.com...
> Hi,
>
> > how to quit excel without saving and suppress the prompt?
> >
> > I am suing excel application for some intermediate work but don't
> > want to save the result in excel
>
> Set the Saved property of all open Workbooks to True.
>
> --
> SvenC