+ Reply to Thread
Results 1 to 2 of 2

MsgBox when an Error occurs

  1. #1
    Vick
    Guest

    MsgBox when an Error occurs

    Is there a way that I can have a message box display when an error is
    received while running a Macro?

    Vick

  2. #2
    Bob Phillips
    Guest

    Re: MsgBox when an Error occurs

    You need to trap the error and display the message. Example

    Sub Test()
    On Error Goto errHandler
    'more code
    Exit Sub

    errHandler:
    Msgbox "some message"
    End Sub

    --

    HTH

    RP
    (remove nothere from the email address if mailing direct)


    "Vick" <[email protected]> wrote in message
    news:[email protected]...
    > Is there a way that I can have a message box display when an error is
    > received while running a Macro?
    >
    > Vick




+ 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