RosettaCodeData/Task/Program-termination/VBA/program-termination.vba

6 lines
274 B
Text
Raw Permalink Normal View History

2019-09-12 10:33:56 -07:00
'In case of problem this will terminate the program (without cleanup):
If problem then End
'As VBA is run within an application, such as Excel, a more rigorous way would be:
If problem then Application.Quit
'This will stop the application, but will prompt you to save work.