Hi,
I am trying using enterprise libray from a script component to log errors in database.
I am getting the following error when it tries to log data
Windows cannot find Microsoft.Practices.ServiceLocation.ActivationException was
unhandled by user code HResultt-2146233088 MessagezActivation error occured while
trying to get instance of type LogWriter, key ? Source=Microsoft.Practices.ServiceLocation
StackTrace: at
Microsoft.Practices.ServiceLocation.ServiceLocatorlmplBase.Getlnstance(Type serviceType.
String key) at
Microsoft.Practices.ServiceLocation.ServiceLocatorlmplBase.Getlnstance[TService]O at
ScriptMain.Input0_ProcesslnputRow(Input0Buffer Row) in
c:\Users\Administrator\AppData\Local\TempU\VstaU5Oc5bdfd83l4l33b336fl3b6d4eb...:line
131 at UserComponentJnput0_Processlnput(InputoBuffer Buffer) in
c:\Users\Administrator\AppData\Local\Temp\1\VstaU5Oc5bdfd83l4l33b336fl3b6d4eb...:line
36 at UserComponent.Processlnput(1nt32 InputlD, String InputName, PipelineBuffer Buffei
OutputNameMap OutputMap) in
c:\Users\Administrator\AppData\Local\TempU\VstaUSOc5bdfd83l4l33b336fl3b6d4eb...:line
27 at Microsoft.SqlServer.Dts.Pipeline.ScriptComponent.Processlnput(1nt32 InputlD,
PipelineBuffer buffer) at
Microsoft.SqlServer.Dts.Pipeline.ScriptComponentHost.Processlnputnt32 inputlD,
PipelineBuffer buffer) InnerException: Microsoft.Practices.Unity.ResolutionFailedException
HResult= -2146233088 Message= Resolution of the dependency failed, type =
Microsoft.Practices.EnterpriseLibrary.Logging.LogWriter, name = (none).Exception
occurred while: while resolving.Exception is: InvalidOperationException - The type LogWriter
cannot be constructed, You must configure the container to supply this
value. At the time of the exception, the container
was: Resolving Microsoft.Practices.EnterpriseLibrary.Logging.LogWriter,(none)
Source= Microsoft.Practices.Unity TypeRequested= LogWriter StackTrace: at
Microsoft.Practices.Unity.UnityContainer.DoBuildUp(Type t, Object existing, String name,
IEnumerablel resolverOverrides). Check the spelling and try again.
I have registered the dlls in GAC as well as places in the DTD\BINN folder.
Am i missing any part.
T


