|
From: Bruno B. <br...@gm...> - 2011-03-30 09:00:49
|
Answer on StackOverflow : http://stackoverflow.com/questions/5366592/how-to-configure-microsoft-enterprise-library-logging-application-block-to-handle <http://stackoverflow.com/questions/5366592/how-to-configure-microsoft-enterprise-library-logging-application-block-to-handle> Subject closed. - Bruno 2011/3/20 Daniel Pincas <dan...@gm...> > Hello! > > First, I love this library. I was in the process of making a simple wrapper > interface for our own loggers when I came across this. Thank you! > > Second, I'm having a small problem getting it up and running. I'm using it, > with EntLib 41. Logging, in a simple ASP.NET MVC application, and whenever > I call it like so: > > public ActionResult Index() > { > > ViewBag.Message = "Welcome to ASP.NET MVC!"; > > ILog log = LogManager.GetCurrentClassLogger(); > > log.Info("Hello world!"); > > return View(); > } > > Instead of logging, it gets caught in an EntLib error because the category > seems to be generated automatically: > > Message: There is no explicit mapping for the categories > 'TestApp.Controllers.HomeController'. > > I've tried tweaking EntLib to accept any category, but there doesn't seem > to be a way to do that. Is there some way of telling the Logger to use the > "General" category? Or is this a bug? > > I'd appreciate any and all help with this problem. Additionally, I've > posted this question on StackOverflow ( > http://stackoverflow.com/questions/5366592/how-to-configure-microsoft-enterprise-library-logging-application-block-to-handle) -- > if you want, you could post your answer there and grab some easy points ;-) > > Thank you so much! > > Cheers, > > Dan Pincas > > > ------------------------------------------------------------------------------ > Colocation vs. Managed Hosting > A question and answer guide to determining the best fit > for your organization - today and in the future. > http://p.sf.net/sfu/internap-sfd2d > _______________________________________________ > Netcommon-developer mailing list > Net...@li... > https://lists.sourceforge.net/lists/listinfo/netcommon-developer > > |