Here you will find an error class called CError that allows you to display a custom dialog box with the option to have a detailed message, a general message, and log the error in a file for later reference. Also uses some JavaScript and DHTML to allow the user to drag the dialog box around.