Question: I am getting this error in my C# application. I am using log4net as a logging tool.

Here is my app.config file:

```xml
<configuration>

  <configSections>
    <section name="log4net" type ="log4net.Config.Log4NetConfigurationSectionHandler,log4net"/>
  </configSections>

  <log4net>
    <root>
      <level value="ALL" />
      <appender-ref ref="myLogger" />
    </root>
    <appender name="myLogger" type="log4net.Appender.RollingFileAppender,log4net">
      <param name="File" value="C:\MyApp\Logs\appLog.txt" />
      <param name="AppendToFile" value="true" />
      <rollingStyle value="Size" />
      <maxSizeRollBackups value="2" />
      <maximumFileSize value="100KB" />
      <staticLogFileName value="true" />
      <datePattern value="yyyyMMdd" />
      <lockingModel value="log4net.Appender.FileAppender+MinimalLock" />
      <immediateFlush value="true" />
      <layout type="log4net.Layout.PatternLayout">
        <conversionPattern value="%date [%thread] %-5level %logger - %message%newline" />
      </layout>
    </appender>
  </log4net>

</configuration>

```

Can anyone please help?

Answer: 
Use this:

```
<lockingModel type="log4net.Appender.FileAppender+MinimalLock" />

```

Note: `type` instead of `value`.
This error can also happen when there is an XML element in the appender configuration but not a matching property in the appender. For example the `BufferingAppenderSkeleton` does not have a property for "LockingModel", so if it's included in the configxml as it is in the above examples, the `XmlConfigurator` will report the same error as in the title