There are many places you can log your errors. My prefrence is to use the windows event logs
You can also have your own text file logging. It can be plain text or an XML file
As Curt mentioned SQL is also another alternative and it is also the easiest to report from if you have a need for that kind of stuff
Each of the above methods has their ups and downs
Logging to the event logs>> Web users have to given rights to write to this log and sys admins sometimes wont like this
Logging to your own text file>> Slower than logging to SQL or Event logs. You have manage the file on your own(i.e. how much can it grow, etc
Logging to SQL server>> Logging credentials might fail
It's up to you to figure out what best fits your application and design the best solution
BTW when you are logging errors to the database it would be better to use different credentials to write to the SQL tables other than the credentials used to access your transactional system. Even that's not fail proof so you have to handle a scenario where the credentials fail
A good place to start might be to look at Microsoft's exception management block
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnbda/html/emab-rm.as
HTH
Suresh
----- gabriel wrote: ----
Curt_C [MVP] wrote
I've always preferred using a DB, like MS SQL, to log to. It allows fo
easier retrieval later and better reporting
How do you log a failed login into the database