For Enterprise Library 6 logging we need to add below mentioned line in Startup.cs for Web application,then only we can able use database logging.
DatabaseFactory.SetDatabaseProviderFactory(new DatabaseProviderFactory());
Same way, where should I add the above mentioned line for WCF Service application to use database logging???
We need to add Global.asax
inside WCF Service application,then use the below mentioned code
protected void Application_Start(object sender, EventArgs e)
{
DatabaseFactory.SetDatabaseProviderFactory(new DatabaseProviderFactory());
}
Then everything will work perfectly...enjoy