logging-log4net-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Tomas Ramirez <tom...@windward.net>
Subject RE: net4log click once projects
Date Fri, 05 Mar 2010 23:27:04 GMT
When this happened to me, it was because log4net couldn't find the config file.  I specified
it directly in XmlConfigurator.Configure and that solved the problem.  There are other ways
to do it too.

- Tomas

-----Original Message-----
From: Velicu [mailto:mvelicu@thermalsystems.ca] 
Sent: Friday, March 05, 2010 4:23 PM
To: log4net-user@logging.apache.org
Subject: net4log click once projects

Hi !

I have an application where I log errors with log4net.
If i run it from Visual studio is ok.If I deployed with click once is not working.Is not creation
the file.

The config.log4net.xml is:

<?xml version="1.0" encoding="utf-8" ?>
  <appender name="Console" type="log4net.Appender.ConsoleAppender">
    <layout type="log4net.Layout.PatternLayout">
      <!-- Pattern to output the caller's file name and line number -->
      <conversionPattern value="%5level [%thread] (%file:%line) - %message%newline" />

  <appender name="RollingFile" type="log4net.Appender.RollingFileAppender">
    <!--    <threshold value="Error" /> -->
    <file value="c:\Temp\myfile.log" />
    <appendToFile value="true" />
    <rollingStyle value="Composite" />
    <maximumFileSize value="1MB" />
    <maxSizeRollBackups value="-1" />
    <datePattern value="'.'yyyyMMdd'.log'" />
    <lockingModel type="log4net.Appender.FileAppender+MinimalLock" />

    <layout type="log4net.Layout.PatternLayout">
      <conversionPattern value="%date %level %thread %logger - %message%newline" />

    <level value="Error" />
    <appender-ref ref="Console" />
    <appender-ref ref="RollingFile" />


What is wrong ?

Thank you !

View this message in context: http://old.nabble.com/net4log-click-once-projects-tp27800445p27800445.html
Sent from the Log4net - Users mailing list archive at Nabble.com.

View raw message