Software >> OS >> Windows >> Scripting >> VBScript >>  How to handle errors during script execution

Err object is built in. Err.Number will contain the error number Eg. Err.Clear ' clear before doing the task ....vbscript tasks If ( Err.Number <> 0) Then .... tasks to do when we have error(s) else .... tasks to do when there are NO errors end if