enterprise-library

Transient Fault Handling with SQL Azure using Entity Framework

淺唱寂寞╮ 提交于 2020-01-10 07:43:09
问题 I currently use SQL Azure and Entity SQL in my application. e.g. Entities model = new Entities(); db_Item item = model.db_Item.First(); Now I want to use the Transient Fault Handling out of the Enterprise Library but there are no examples or solutions that I can find that would allow me to do something like override the Entities class, so I don't have to update my code in hundreds of places. Could someone please provide more information on how this could be done? 回答1: Going through what I

Changing connection string at runtime in Enterprise Library

吃可爱长大的小学妹 提交于 2020-01-09 20:09:27
问题 Is there a way to change the connection string of a DataBase object in Enterprise Library at runtime? I've found this link but its a little bit outdated (2005) I've also found this but it seems to apply to .Net in general, I was wondering if there was something that could be done specifically for EntLib. I was just passing the connection string name to the CreateDatabase() method in DatabaseFactory object and that worked til yesterday that my project manager asked me to support more than one

Changing connection string at runtime in Enterprise Library

纵饮孤独 提交于 2020-01-09 20:07:56
问题 Is there a way to change the connection string of a DataBase object in Enterprise Library at runtime? I've found this link but its a little bit outdated (2005) I've also found this but it seems to apply to .Net in general, I was wondering if there was something that could be done specifically for EntLib. I was just passing the connection string name to the CreateDatabase() method in DatabaseFactory object and that worked til yesterday that my project manager asked me to support more than one

Changing connection string at runtime in Enterprise Library

别等时光非礼了梦想. 提交于 2020-01-09 20:07:40
问题 Is there a way to change the connection string of a DataBase object in Enterprise Library at runtime? I've found this link but its a little bit outdated (2005) I've also found this but it seems to apply to .Net in general, I was wondering if there was something that could be done specifically for EntLib. I was just passing the connection string name to the CreateDatabase() method in DatabaseFactory object and that worked til yesterday that my project manager asked me to support more than one

Where Enterprise Library Configuration Editor for Visual Studio 2015?

邮差的信 提交于 2020-01-07 04:22:10
问题 Where Enterprise Library Configuration Editor for Visual Studio 2015? Is this feature missing for Visual Studio 2015? I'm on EL5. 回答1: EntperiseLibrary.Config V6 extension is not supporting Visual Studio 2015. So you need to update the config file to add the support. You can find a compatible version for VS 2015 here It worked for me. 来源: https://stackoverflow.com/questions/32189967/where-enterprise-library-configuration-editor-for-visual-studio-2015

.net Mef with Enterprise Library 5.0

倾然丶 夕夏残阳落幕 提交于 2020-01-04 15:58:55
问题 I am wanting to use mef with the Logging and Exception Blocks of Enterprise Library 5.0. What I am doing is I have a plugin defined that MEF is looking for in a directory. It then imports it for me. However I am using logging and exception handling in the plugin also and I would like to be able to insert the instance of the LogWriter and ExceptionWriter via mef. The example shows you how to do it with unity which won't work since I am using mef to get the plugin and instantiate it. thanks 回答1

.net Mef with Enterprise Library 5.0

半城伤御伤魂 提交于 2020-01-04 15:58:18
问题 I am wanting to use mef with the Logging and Exception Blocks of Enterprise Library 5.0. What I am doing is I have a plugin defined that MEF is looking for in a directory. It then imports it for me. However I am using logging and exception handling in the plugin also and I would like to be able to insert the instance of the LogWriter and ExceptionWriter via mef. The example shows you how to do it with unity which won't work since I am using mef to get the plugin and instantiate it. thanks 回答1

Enterprise Library 5.0 installation error

喜夏-厌秋 提交于 2020-01-04 05:44:05
问题 "This application requires .NET Framework 3.5 SP1. Please install the .net framework then run this installer again" But the system has already installed .net Framework 4.0. In add remove programs I can see the following two entries: 1: Microsoft .NET Framework 4 Client Profile 2: Microsoft .NET Framework 4 Extended. Any ideas why the installation is failing? Update - Repro steps: XP was installed with SP2. Installed XP3 Installed IE 8 Installed VS2010 Professional - 10.0.30319 Tried to

Microsoft Enterprise Library Type Load Exception Couldnot load Microsoft.Practices.EnterpriseLibrary.Common.Configuration.EnterpriseLibraryContainer

风格不统一 提交于 2020-01-04 02:45:14
问题 I am trying to sort out a friends service. Basically it gets into error as soon as I start it in constructor. Here are the code fragments. public class DefaultCacheManager : ICacheManager { private readonly Microsoft.Practices.EnterpriseLibrary.Caching.ICacheManager _cacheManager; public DefaultCacheManager() { //Code blows here _cacheManager = CacheFactory.GetCacheManager(); } The error I get is below. Unhandled Exception: System.TypeInitializationException: The type initializer for 'Test

Simple Enterprise Library console application refuses to compile

浪尽此生 提交于 2020-01-03 21:01:30
问题 I just downloaded and installed Microsoft Enterprise Library 5.0. I fired up VS 2010 to play with EL 5 and created a very simple console application. However, it would not compile. I got the following error: The type or namespace name 'Data' does not exist in the namespace 'Microsoft.Practices.EnterpriseLibrary' (are you missing an assembly reference?) I added Microsoft.Practices.EnterpriseLibrary.Common, Microsoft.Practices.EnterpriseLibrary.Data , and Microsoft.Practices.Unity references to