on error to message box

Keith.Jackson

Board Regular
Joined
Mar 31, 2005
Messages
115
I have an on error GoTo going to a label before a message box that tells what the error is.

How can I make the code skip this message box when there is no error?

thanks
 

Some videos you may like

Excel Facts

How to find 2nd largest value in a column?
MAX finds the largest value. =LARGE(A:A,2) will find the second largest. =SMALL(A:A,3) will find the third smallest

Norie

Well-known Member
Joined
Apr 28, 2004
Messages
76,056
Office Version
  1. 365
Platform
  1. Windows
Try something like this.
Code:
ErrHandler:
    If Err <> 0 Then
        MsgBox "Error"
    End If
 

Watch MrExcel Video

Forum statistics

Threads
1,118,335
Messages
5,571,600
Members
412,407
Latest member
ElmerCC
Top