This is a migrated thread and some comments may be shown as answers.

Issue after upgrading

2 Answers 192 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Kevin
Top achievements
Rank 1
Kevin asked on 07 Jun 2016, 10:13 PM

I needed up update our project from .Net 4.0 to 4.5 for another 3rd party DLL.  We were running 2014.2.918.1 of Data Access.

I removed the old data access DLLs and used NuGet to install 2016.1.244.1  I get the following error when compiling.  I have searched the project for 2014.2.918.1 but I cannot find any references to it.  Why is the new installation looking for an old OPenAccess.35 dll?

Error103Could not load file or assembly 'Telerik.OpenAccess.35.Extensions, Version=2014.2.918.1, Culture=neutral, PublicKeyToken=7ce17eeaf1d59342' or one of its dependencies. General Exception (Exception from HRESULT: 0x80131500)
ExceptionString:
System.IO.FileLoadException: Could not load file or assembly 'Telerik.OpenAccess.35.Extensions, Version=2014.2.918.1, Culture=neutral, PublicKeyToken=7ce17eeaf1d59342' or one of its dependencies. General Exception (Exception from HRESULT: 0x80131500)
File name: 'Telerik.OpenAccess.35.Extensions, Version=2014.2.918.1, Culture=neutral, PublicKeyToken=7ce17eeaf1d59342' ---> System.Exception: The referenced assembly 'C:\xxxents\Visual Studio 2013\Projects\xxxxxxx\packages\Telerik.DataAccess.Core.2016.1.224.1\lib\net40\Telerik.OpenAccess.35.Extensions.dll' has the wrong version; expected Version=2014.2.918.1 but found Version=2016.1.224.1.
   at Telerik.OpenAccess.SPI.AssemblyProvider.LoadFromReferences(String assemblyName)
   at Telerik.OpenAccess.SPI.AssemblyProvider.RefResolveEventHandler(Object sender, ResolveEventArgs args)
   at System.AppDomain.OnAssemblyResolveEvent(RuntimeAssembly assembly, String assemblyFullName)
   at System.RuntimeTypeHandle.GetTypeByName(String name, Boolean throwOnError, Boolean ignoreCase, Boolean reflectionOnly, StackCrawlMarkHandle stackMark, IntPtr pPrivHostBinder, Boolean loadTypeFromPartialName, ObjectHandleOnStack type)
   at System.RuntimeTypeHandle.GetTypeByName(String name, Boolean throwOnError, Boolean ignoreCase, Boolean reflectionOnly, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean loadTypeFromPartialName)
   at System.RuntimeType.GetType(String typeName, Boolean throwOnError, Boolean ignoreCase, Boolean reflectionOnly, StackCrawlMark& stackMark)
   at System.Type.GetType(String typeName)
   at Telerik.OpenAccess.Sdk.Enhancer.Enhancer.CrossDomainRunImpl(AssemblyLoader assemblyLoader)
   at Telerik.OpenAccess.Sdk.Enhancer.EnhancerBase.CrossDomainRun()

 

2 Answers, 1 is accepted

Sort by
0
Accepted
Doroteya
Telerik team
answered on 10 Jun 2016, 08:19 AM
Hi Kevin,

Literally the error means that the Enhancer tool, which comes with the installed version of Data Access resolved the Telerik.OpenAccess.35.Extensions assembly with the version from the NuGet packages. This conflict arises because each version of Enhancer is bound to the corresponding version of the Telerik.OpenAccess.* assemblies. 

Additionally, the Data Access NuGet packages are not designed to replace the installed version of Data Access. They work only with Data Access fluent model. Therefore, in order to successfully upgrade your solution, you need to apply the workflow described in this blog post. Note that the workflow requires you to have Data Access 2014.2.918.1 (or higher) installed on the dev machine, where you will upgrade the solution.

I would also recommend you to manually delete the bin and obj folders throughout the solution after executing the workflow and before building it.

I hope this helps.

Regards,
Doroteya
Telerik
 
Check out the latest announcement about Telerik Data Access vNext as a powerful framework able to solve core development problems.
0
Kevin
Top achievements
Rank 1
answered on 10 Jun 2016, 01:31 PM

Thank you for the information.  Yesterday I found this post which helped me resolve the issue.

http://www.telerik.com/blogs/telerik-data-access-deployment-dos-and-don-ts

 

 

Tags
General Discussions
Asked by
Kevin
Top achievements
Rank 1
Answers by
Doroteya
Telerik team
Kevin
Top achievements
Rank 1
Share this question
or