if debugMode is true, then it will log to the file specified in web.config key "errorLogFile"
if the file is not specified in web.config, then no logging will occur
writes the passed errormessage to the log file
if debugMode is true, then it will log to the file specified in web.config key "errorLogFile"
if the file is not specified in web.config, then no logging will occur
loops through the passed in System.Exception object and writes the messages