LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming,microsoft.public.word.vba.beginners
external usenet poster
 
Posts: 1
Default Beginners question: how to stop / abort execution of vba program

Hi,

how can I abort / cancel a vba program immediately, without returning to the
calling procedure?
I already have a rather complex vba application with many sub's and
functions.
The only thing I found by now is the "stop" command, but it enters debugging
mode, so this is not what I want.
i want to have something like this:

Sub Main
CheckValues
MsgBox "Completed successfully"
End Sub

Sub CheckValues
If SomeVar = SomeValue Then
MsgBox "Error"
'now stop it
End If
End Sub


 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Beginners Question GordyB Excel Discussion (Misc queries) 3 February 1st 10 10:33 PM
Beginners Question Black_op51 Excel Discussion (Misc queries) 6 November 8th 06 11:46 PM
Stop Execution ArthurJ Excel Programming 2 September 10th 05 04:41 PM
Program execution prob PLPE[_11_] Excel Programming 2 June 30th 05 01:09 PM
stop execution al Excel Programming 3 October 2nd 04 01:20 AM


All times are GMT +1. The time now is 05:29 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"