Add Log4Net to WCF application

Adding log4Net to your WCF application is straightforward.
a. Add Log4Net library into your application using Nuget.
b. Add the following code to your web.config file.

c. Add the following code to your application’s property file.

d. Add code to load Log4Net configuration from web.config file.

e. You can now log errors using your CustomLog4Net._log Log4Net instance.

You may also like

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.