开发者

Where to store ExceptionLog in Windpows?

Hi,

We have a WinForm application running och Windows. This application offers extended logging on the client of Exceptions. Until now we have placed this XML file in the root off the application but Its not always that the correct per开发者_JAVA百科missions exists to write in this file.

Is there any best practice for this? Where should the ExceptionLog be placed and how do we handle the permissions?

Maby the log should be placed in a user folder (C:\Users\UserX)

BestRegards


I recommend you to use some library for exception logging. For exapmle log4net or nlog. They allow you to change the way logs are written. Log4net has big set of different appenders that can log to database, text or xml files, event log and even send email. Log4net could be configured without recompiling your application, according clients machine.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜