+ Reply to Thread
Results 1 to 6 of 6

disable msgbox of a macro run from a different workbook

  1. #1
    Registered User
    Join Date
    04-30-2009
    Location
    Spain
    MS-Off Ver
    Excel 2010
    Posts
    88

    disable msgbox of a macro run from a different workbook

    Hi, I would like Excel to automatically click the ok button in a simple Msgbox if has been popped up or to avoid that the msgbox popped up. I've got some reasons why not changing the msgbox code. any help would be apreciated.
    Last edited by dvb_24; 07-24-2009 at 12:32 PM.

  2. #2
    Registered User
    Join Date
    04-30-2009
    Location
    Spain
    MS-Off Ver
    Excel 2010
    Posts
    88

    Re: disable msgbox of a macro run from a different workbook

    Can anyone help with this?

  3. #3
    Forum Expert davegugg's Avatar
    Join Date
    12-18-2008
    Location
    WI, US
    MS-Off Ver
    2010
    Posts
    1,884

    Re: disable msgbox of a macro run from a different workbook

    I had a similar situation where I had a form pop up in the workbook.open event. To get around it I had to write code that said if the workbook was opened while a second workbook was open, to not show the form. Would this solution work for you? If so I'll post the code.
    Is your code running too slowly?
    Does your workbook or database have a bunch of duplicate pieces of data?
    Have a look at this article to learn the best ways to set up your projects.
    It will save both time and effort in the long run!


    Dave

  4. #4
    Registered User
    Join Date
    04-30-2009
    Location
    Spain
    MS-Off Ver
    Excel 2010
    Posts
    88

    Re: disable msgbox of a macro run from a different workbook

    Yes, thanks it is very similar to what I need as the msgbox is generated for a macro in a different workbook

  5. #5
    Forum Expert davegugg's Avatar
    Join Date
    12-18-2008
    Location
    WI, US
    MS-Off Ver
    2010
    Posts
    1,884

    Re: disable msgbox of a macro run from a different workbook

    Here is what I used:

    Please Login or Register  to view this content.

  6. #6
    Registered User
    Join Date
    04-30-2009
    Location
    Spain
    MS-Off Ver
    Excel 2010
    Posts
    88

    Re: disable msgbox of a macro run from a different workbook

    Thanks Dave for the code. The "problem" I have is that the msgbox pops up not because an error message but for code from a different workbook that, for different reasons I shouldn't modify so need something to prevent from the msgbox that stops the executgion of my code.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1