Eliminating Excel msgbox from popping up while macro is running.

  • Thread starter Thread starter dpdutke
  • Start date Start date
D

dpdutke

I would like to keep the following msgbox from popping up
whenever my macro merges like cells using the "Format
Cells", "Alignment", "Merge cells" property commands:

"The selection contains multiple data values. Merge into
one cell will keep the upper-left most data only."

Thanks!

dpdutke
 
give this a try,
Application.DisplayAlerts = False
'Your Code
Application.DisplayAlerts = True


--
Paul B
Always backup your data before trying something new
Using Excel 2000 & 97
Please post any response to the newsgroups so others can benefit from it
** remove news from my email address to reply by email **
 
Hi,

set Application.DisplayAlerts to False before merging the cells and set it back to True.

In your example;

Application.DisplayAlerts=False
Range("A1:A5").merge True
application.DisplayAlerts=True

--
Regards

Haldun Alay

To e-mail me, please remove AT and DOT from my e-mail address.



"dpdutke" <[email protected]>, iletide sunu yazdi I would like to keep the following msgbox from popping up
whenever my macro merges like cells using the "Format
Cells", "Alignment", "Merge cells" property commands:

"The selection contains multiple data values. Merge into
one cell will keep the upper-left most data only."

Thanks!

dpdutke
 
Back
Top