![]() |
Warnings in Excel
Can someone please tell me how to turn off warnings in Excel VBA in the way
you would do this in Access? DoCmd.SetWarnings False Whenever the code closes a workbook, the prompt is displayed saying I've pasted a large amount of data to the clipboard, etc. and this needs to be part of an automated process. Also how would you trigger a macro to run when a particular workbook is opened? Thanks in advance, -- Glenn |
Warnings in Excel
Glenn Suggs wrote: Can someone please tell me how to turn off warnings in Excel VBA in the way you would do this in Access? DoCmd.SetWarnings False Whenever the code closes a workbook, the prompt is displayed saying I've pasted a large amount of data to the clipboard, etc. and this needs to be part of an automated process. Also how would you trigger a macro to run when a particular workbook is opened? Thanks in advance, -- Glenn Try Application.DisplayAlerts = False That should take care of most (all?) such prompts |
Warnings in Excel
Use the Workbook_Open event in the ThisWorkbook class.
Also how would you trigger a macro to run when a particular workbook is opened? "Glenn Suggs" wrote: Can someone please tell me how to turn off warnings in Excel VBA in the way you would do this in Access? DoCmd.SetWarnings False Whenever the code closes a workbook, the prompt is displayed saying I've pasted a large amount of data to the clipboard, etc. and this needs to be part of an automated process. Also how would you trigger a macro to run when a particular workbook is opened? Thanks in advance, -- Glenn |
Warnings in Excel
Make sure you turn them back on again when you close the workbook.
application.displayalerts = true -- JNW "Bill Pfister" wrote: Use the Workbook_Open event in the ThisWorkbook class. Also how would you trigger a macro to run when a particular workbook is opened? "Glenn Suggs" wrote: Can someone please tell me how to turn off warnings in Excel VBA in the way you would do this in Access? DoCmd.SetWarnings False Whenever the code closes a workbook, the prompt is displayed saying I've pasted a large amount of data to the clipboard, etc. and this needs to be part of an automated process. Also how would you trigger a macro to run when a particular workbook is opened? Thanks in advance, -- Glenn |
All times are GMT +1. The time now is 03:22 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com