System.IO.FileNotFoundException: Could not load file or assembly

in Help Center
Hi,
We've just upgraded from Ice 3.0.1 to Ice 3.2.1 and we are having a lot of trouble when trying to use Ice through c#.
We have regenerated the .cs files using slice2cs, and the project compiles against them; however, when we try and run the project, we are getting a strange FileNotFound exception which seems to be causing an Ice.NoObjectFactoryException.
The actual file/assembly that is being reported as missing seems to be different each time; it varies between vs classes and other dependent libraries of the project.
This happens both when you run the project from within VS2005, as well as when you run the binaries outside of VS.
This did not used to happen when we were on 3.0.1, and our c++ and java libraries have been upgraded to 3.2.1 using the same slice files, so I am very unsure what the problem is here.
ML.EquityLinked.Gps.Vision.Parameters.ParameterDataException: Failed to Load Data ---> Ice.NoObjectFactoryException
reason = (null)
type = "::paramarama::Parameter"
at Ice.ObjectPrxHelperBase.handleExceptionWrapper__(ObjectDel_ delegate, LocalExceptionWrapper ex) in f:\src\vc80\stage\debug\IceCS-3.2.1\src\Ice\Proxy.cs:line 995
at correlations.ParameterServicePrxHelper.getCurrentValidParameters(Key[] specs, Context context__, Boolean explicitContext__) in C:\projects\nepx\paramarama\correlations.cs:line 2887
at correlations.ParameterServicePrxHelper.getCurrentValidParameters(Key[] specs) in C:\projects\nepx\paramarama\correlations.cs:line 2860
at ML.EquityLinked.Gps.EPX.IceParameterService.GetCurrentValidParameter(Key id) in C:\projects\nepx\MerrillLynch.EPX\IceParameterService.cs:line 97
at ML.EquityLinked.Gps.Vision.Parameters.EpxApiWrapper.GetEpxXml(String key_, String type_, String source_, String format_, DateTime validTime, Metadata& meta_) in C:\projects\GPSVision\Vision.ParameterData\EpxApiWrapper.cs:line 480
Caused by: System.IO.FileNotFoundException: Could not load file or assembly 'Microsoft.Vbe.Interop, Version=10.0.4504.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified.
at System.Reflection.Assembly.nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, Assembly locationHint, StackCrawlMark& stackMark, Boolean throwOnFileNotFound, Boolean forIntrospection)
at System.Reflection.Assembly.InternalLoad(AssemblyName assemblyRef, Evidence assemblySecurity, StackCrawlMark& stackMark, Boolean forIntrospection)
at System.Reflection.Assembly.Load(AssemblyName assemblyRef)
at IceInternal.AssemblyUtil.loadReferencedAssemblies(Assembly a) in f:\src\vc80\stage\debug\IceCS-3.2.1\src\Ice\AssemblyUtil.cs:line 163
at IceInternal.AssemblyUtil.loadAssemblies() in f:\src\vc80\stage\debug\IceCS-3.2.1\src\Ice\AssemblyUtil.cs:line 149
at IceInternal.AssemblyUtil.findType(String csharpId) in f:\src\vc80\stage\debug\IceCS-3.2.1\src\Ice\AssemblyUtil.cs:line 56
at IceInternal.BasicStream.loadObjectFactory(String id) in f:\src\vc80\stage\debug\IceCS-3.2.1\src\Ice\BasicStream.cs:line 1806
We've just upgraded from Ice 3.0.1 to Ice 3.2.1 and we are having a lot of trouble when trying to use Ice through c#.
We have regenerated the .cs files using slice2cs, and the project compiles against them; however, when we try and run the project, we are getting a strange FileNotFound exception which seems to be causing an Ice.NoObjectFactoryException.
The actual file/assembly that is being reported as missing seems to be different each time; it varies between vs classes and other dependent libraries of the project.
This happens both when you run the project from within VS2005, as well as when you run the binaries outside of VS.
This did not used to happen when we were on 3.0.1, and our c++ and java libraries have been upgraded to 3.2.1 using the same slice files, so I am very unsure what the problem is here.
ML.EquityLinked.Gps.Vision.Parameters.ParameterDataException: Failed to Load Data ---> Ice.NoObjectFactoryException
reason = (null)
type = "::paramarama::Parameter"
at Ice.ObjectPrxHelperBase.handleExceptionWrapper__(ObjectDel_ delegate, LocalExceptionWrapper ex) in f:\src\vc80\stage\debug\IceCS-3.2.1\src\Ice\Proxy.cs:line 995
at correlations.ParameterServicePrxHelper.getCurrentValidParameters(Key[] specs, Context context__, Boolean explicitContext__) in C:\projects\nepx\paramarama\correlations.cs:line 2887
at correlations.ParameterServicePrxHelper.getCurrentValidParameters(Key[] specs) in C:\projects\nepx\paramarama\correlations.cs:line 2860
at ML.EquityLinked.Gps.EPX.IceParameterService.GetCurrentValidParameter(Key id) in C:\projects\nepx\MerrillLynch.EPX\IceParameterService.cs:line 97
at ML.EquityLinked.Gps.Vision.Parameters.EpxApiWrapper.GetEpxXml(String key_, String type_, String source_, String format_, DateTime validTime, Metadata& meta_) in C:\projects\GPSVision\Vision.ParameterData\EpxApiWrapper.cs:line 480
Caused by: System.IO.FileNotFoundException: Could not load file or assembly 'Microsoft.Vbe.Interop, Version=10.0.4504.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified.
at System.Reflection.Assembly.nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, Assembly locationHint, StackCrawlMark& stackMark, Boolean throwOnFileNotFound, Boolean forIntrospection)
at System.Reflection.Assembly.InternalLoad(AssemblyName assemblyRef, Evidence assemblySecurity, StackCrawlMark& stackMark, Boolean forIntrospection)
at System.Reflection.Assembly.Load(AssemblyName assemblyRef)
at IceInternal.AssemblyUtil.loadReferencedAssemblies(Assembly a) in f:\src\vc80\stage\debug\IceCS-3.2.1\src\Ice\AssemblyUtil.cs:line 163
at IceInternal.AssemblyUtil.loadAssemblies() in f:\src\vc80\stage\debug\IceCS-3.2.1\src\Ice\AssemblyUtil.cs:line 149
at IceInternal.AssemblyUtil.findType(String csharpId) in f:\src\vc80\stage\debug\IceCS-3.2.1\src\Ice\AssemblyUtil.cs:line 56
at IceInternal.BasicStream.loadObjectFactory(String id) in f:\src\vc80\stage\debug\IceCS-3.2.1\src\Ice\BasicStream.cs:line 1806
0
Comments
Please try the attached patch, and let me know if that resolves the problem.
take care
tom