MrExcel Publishing
Your One Stop for Excel Tips & Solutions

Yes it is OK!!!!!!using VBA


Posted by Eric on July 16, 2001 7:12 PM

ok--So I have a macro that creates quite a few new workbooks one at a time, saves it as filename "Temp.xls", then the macro renames the workbook, based on certain criteria found in the workbook. It all works very well, EXCEPT, It keeps asking me it it is ok the replace the existing "Temp.xls". How do I tell it YES through the code, so it stops pausing the code, waiting for my input.......I'm Stumped!!

Thanks in advance for any help!!

Eric


Posted by Ivan F Moala on July 16, 2001 9:07 PM


Sub yoursub()

some code
...
...

application.displayalerts=false

some more code
...
...

application.displayalerts=true
End Sub

Ivan