I need to use “Enterprise Library 6.0.x” for logging with Visual studio 2015. Before this I have worked with Log4Net and I know how to write log files using log4net. But I am using “Enterprise Library” first time.
I have installed a Nuget package “EnterpriseLibrary.Logging” version 6.0.1304 for Visual Studio 2015 Enterprise. Now I am looking for a wizard tool from where I can configure it for logging.
I have gone through some blog posts and they were suggesting to execute some powerShell script written in “install.ps1” file but it fails due to some admin right issue because I do not have admin right on the system.
I have also visited following links but didn’t help me:
Where Enterprise Library Configuration Editor for Visual Studio 2015?
Error writing to file when installing Visual studio 2015 Enterprise
Please suggest some solution or links for good documentation to use Enterprise Library 6.0.x with Visual Studio 2015 without installing .exe file which require admin rights.
I have resolved it by using the following steps:
Downloaded “Microsoft.Practices.EnterpriseLibrary.ConfigConsole.V6.VS2015.vsix” from here and installed it.
I am not sure that this .vsix file is trusted or not but I didn't find it on Microsoft website. If someone is having a link from trusted source then please provide that link.
after installing it, open the project in visual studio and then install NuGet packages for Enterprise Library. then go the file web.config and right click on it to edit the server configuration for Enterprise library 6.0.x. as shown in following screenshot.
it will open a new window for configuration. Now any configuration can be added for enterprise library. right now I am going to add logging setting as shown in following screenshot.
After adding it will look like following screenshot.
it can be customized as per requirement and after saving it will update config file.