P
PatrickS
One spreadsheet I'm on has textboxes on each sheet containing comments aimed
at the user, however sometimes the comments they want to enter are to big to
be printed, so I've ended up opening word from Excel in such circumstances,
then copying the text of the comments to the document. It then saves the
document and closes word and also stops the textboxes from being included in
any printout. I also have error handling that attempts to properly close word
and exit gracefully.
However I've noticed that when an error handling code is executed word asks
me if I want to save the file. I'm aware that word has the DisplayAlerts
property but uses different values from excel, and have added the pre-defined
constants to my code so that I could use pre-existing code without having to
go through and make corrections. The following two lines of code should, I
believe, end up with alerts in words disabled from excel. However this only
works when I step through the code. Running the code normally results in the
save alert still being displayed. Is there any reason for this?
WD.DisplayAlerts = wdAlertsNone
WD.Quit
Thanks for any help in advance.
at the user, however sometimes the comments they want to enter are to big to
be printed, so I've ended up opening word from Excel in such circumstances,
then copying the text of the comments to the document. It then saves the
document and closes word and also stops the textboxes from being included in
any printout. I also have error handling that attempts to properly close word
and exit gracefully.
However I've noticed that when an error handling code is executed word asks
me if I want to save the file. I'm aware that word has the DisplayAlerts
property but uses different values from excel, and have added the pre-defined
constants to my code so that I could use pre-existing code without having to
go through and make corrections. The following two lines of code should, I
believe, end up with alerts in words disabled from excel. However this only
works when I step through the code. Running the code normally results in the
save alert still being displayed. Is there any reason for this?
WD.DisplayAlerts = wdAlertsNone
WD.Quit
Thanks for any help in advance.