david7777777777
Programmer
I'm wondering if someone can provide me with a simple example of how you would handle an error or is it too complex to provide a simple example?
Here's the scenario:
Let's say I was entering a new employee record using my ASP page to my SQL 2000 database, and the data I am entering would cause a duplicate value (employee_number)to be made in the primary key field for this table (tbl_employees) and SQL returns error # 123 for example. Right now, the user would see nothing more than a browser page saying "this page cannot be loaded" or something like that.
I would like to set up my ASP page so it gives the user a more descriptive error message, with a dialog box or whatever, so they know what's going wrong and can better understand how to avoid getting the error again. Thanks.
Here's the scenario:
Let's say I was entering a new employee record using my ASP page to my SQL 2000 database, and the data I am entering would cause a duplicate value (employee_number)to be made in the primary key field for this table (tbl_employees) and SQL returns error # 123 for example. Right now, the user would see nothing more than a browser page saying "this page cannot be loaded" or something like that.
I would like to set up my ASP page so it gives the user a more descriptive error message, with a dialog box or whatever, so they know what's going wrong and can better understand how to avoid getting the error again. Thanks.