ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   On error (https://www.excelbanter.com/excel-programming/296143-error.html)

Todd Huttenstine[_3_]

On error
 
Is "On error exit sub" valid? I am trying to use that and VBA does not like
that...

Todd



JE McGimpsey

On error
 
Did you look at the Help, Todd?

You can use a label just before the end of the sub:

On Error GoTo Exit_Sub
'do stuff
Exit_Sub:
End Sub


In article ,
"Todd Huttenstine" wrote:

Is "On error exit sub" valid? I am trying to use that and VBA does not like
that...

Todd


Todd Huttenstine[_3_]

On error
 
oh ok thanks. Yeah I just used a label but for some reason I thought on
error exit sub was an actual command.


"JE McGimpsey" wrote in message
...
Did you look at the Help, Todd?

You can use a label just before the end of the sub:

On Error GoTo Exit_Sub
'do stuff
Exit_Sub:
End Sub


In article ,
"Todd Huttenstine" wrote:

Is "On error exit sub" valid? I am trying to use that and VBA does not

like
that...

Todd





All times are GMT +1. The time now is 02:58 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com