hi again all,
is there a way of making some sort of global error system, so if there is an error within the whole program it can go to one main errorHandler instead of what i do wich is make lots of little errorHandlers for every component?
thanks
Printable View
hi again all,
is there a way of making some sort of global error system, so if there is an error within the whole program it can go to one main errorHandler instead of what i do wich is make lots of little errorHandlers for every component?
thanks
In a module write this code
VB Code:
Public sub ErrorDisplay(showError as boolean) If showError Then Msgbox "Error :" & Err.Number & " " & Err.Description,vbOKOnly End if ' Now in any function, you write lines like this Private Sub Command1_Click() On Error Goto ED '<your code goes here... Exit Sub ED: ErrorDisplay True
HTH :)