ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   close excel application. (https://www.excelbanter.com/excel-programming/314308-close-excel-application.html)

Vj

close excel application.
 
Hi,

Is there any way I can control the dialog box which prompts to save the
changes of the workbook? Basically I dont want to display the dialog box when
they user clicks on cross.

Thanks

Bob Phillips[_6_]

close excel application.
 
Application.DisplayAlerts = False

.....

Application.DisplayAlerts = True

--

HTH

RP

"VJ" wrote in message
...
Hi,

Is there any way I can control the dialog box which prompts to save the
changes of the workbook? Basically I dont want to display the dialog box

when
they user clicks on cross.

Thanks




N10

close excel application.
 
HI VJ

This what I use hope it helps

Application.AlertBeforeOverwriting = False
ThisWorkbook.Close savechanges:=False

This closes the work book with no prompt and does not save changes.

You could easily ammend the code to save with no alerts and close.

Best N10



"VJ" wrote in message
...
Hi,

Is there any way I can control the dialog box which prompts to save the
changes of the workbook? Basically I dont want to display the dialog box
when
they user clicks on cross.

Thanks




Dave Peterson[_3_]

close excel application.
 
..alertbeforeoverwriting refers to the warning you get when you drag cells over
non-empty cells.

Not overwriting the another file.

N10 wrote:

HI VJ

This what I use hope it helps

Application.AlertBeforeOverwriting = False
ThisWorkbook.Close savechanges:=False

This closes the work book with no prompt and does not save changes.

You could easily ammend the code to save with no alerts and close.

Best N10

"VJ" wrote in message
...
Hi,

Is there any way I can control the dialog box which prompts to save the
changes of the workbook? Basically I dont want to display the dialog box
when
they user clicks on cross.

Thanks


--

Dave Peterson



All times are GMT +1. The time now is 04:20 PM.

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