I am opening a file with a macro and the file I am opening has a msgbox that opens right a way. I would like to close it so that my macro process can continue.
Can this be done?
![]()
Please Login or Register to view this content.
I am opening a file with a macro and the file I am opening has a msgbox that opens right a way. I would like to close it so that my macro process can continue.
Can this be done?
![]()
Please Login or Register to view this content.
You can disable events before you open the file to prevent the workbook_open event from triggering.
Don't forget to turn them back on.
Entia non sunt multiplicanda sine necessitate
I have tried something like that, but it did not work
Code I used was
Application.DisplayAlerts = False
Application.DisplayAlerts = True
Is this the same thing?
What is the source of the message box and what inormation is it displaying.
i.e is it a macro generated or an Excel standard message like when you open a password protected or read only file
Please Read Forum Rules Before Posting
Wrap VBA code by selecting the code and clicking the # icon or Read This
How To Cross Post politely
Top Excel links for beginners to Experts
If you are pleased with a member's answer then use the Scales icon to rate it
If my reply has assistedor failed to assist you
I welcome your Feedback.
the message box was made with a form and is displayed instinly when you open the file and it states the General Information about this file for those who refference it's data. like my selef.
This is the code that displays the message, but I can't change any thing in that file.
and This code is located in the folder “Microsoft excel object” and named “ThisWorkbook”
![]()
Please Login or Register to view this content.
No.Originally Posted by CityMPLSEmpolyee
![]()
Please Login or Register to view this content.
If the msgbox/userform is a necessary item, can you use a timer to display the msgbox/userform for say 5 seconds and then unload it and move on?
Life is like a roll of toilet paper. The closer it gets to the end, the faster it goes.
John Wright
first to Shg thank you your code worked,
and to answer jwright650
I don't have right permisstion to the file that I am reffernceing so I can't edit that code
Solved
Last edited by CityMPLSEmpolyee; 03-04-2011 at 11:54 AM. Reason: to note Solved
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks