Supressing Debug

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Is there a way, using VB Script, to supress the debugger from coming up when
an error occurs in a script?
And is it true that there is no error handler in VB Script?

Thanks,
Robert
 
And is it true that there is no error handler in VB Script?
You have to code your own error handler. Most just put in On Error, do
next.

Hollis D. Paul [MVP - Outlook]
Mukilteo, WA USA
 
I think you mean On Error Resume Next, Hollis.

Robert, once you add On Error Resume Next, you can also add checkpoints where you think the code might encounter an error and test for the error condition:

If Err <> 0 Then
' there is an error
' do something about it
' then clear it
Err.Clear
End If

--
Sue Mosher, Outlook MVP
Author of Configuring Microsoft Outlook 2003

and Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers



Hollis D. Paul said:
And is it true that there is no error handler in VB Script?
You have to code your own error handler. Most just put in On Error, do
next.

Hollis D. Paul [MVP - Outlook]
Mukilteo, WA USA
 
Thanks Sue,

I had already stumbled my way through that. Pretty cludgy though, of course
my code has no places where an error might occur....ahem!

Sue Mosher said:
I think you mean On Error Resume Next, Hollis.

Robert, once you add On Error Resume Next, you can also add checkpoints where you think the code might encounter an error and test for the error condition:

If Err <> 0 Then
' there is an error
' do something about it
' then clear it
Err.Clear
End If

--
Sue Mosher, Outlook MVP
Author of Configuring Microsoft Outlook 2003

and Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers



Hollis D. Paul said:
And is it true that there is no error handler in VB Script?
You have to code your own error handler. Most just put in On Error, do
next.

Hollis D. Paul [MVP - Outlook]
Mukilteo, WA USA
 
Sue Mosher said:
I think you mean On Error Resume Next, Hollis.
Yes, indeed I did. I was groping for the right words, but they
wouldn't appear at my fingertips. But I figured any VB programmer
could figure it out. Thanks for filling in the senior moment lapse.

Hollis D. Paul [MVP - Outlook]
Mukilteo, WA USA
 
Back
Top