How to reference a unsigned dll with different versions in visual studio 2019

0

This is a WPF application on the front end which is the migration tool.

I have a dll which i'm trying to reference both an older version and new version.

The purpose is to use it for migration and de-migration purposes between versions of the product.

example (versions numbers are an example)

I have a release 1.0.15 of the product (.exe file) and it refernces an assembly with some pocos (this assembly version is 2.0.1.0, dll file) which are serialised to json and stored in the database. I then modify the poco object in version 1.0.16 of the product (poco assembly version now is 2.0.2.0). Now when i try to desrealised the json object it longer works as json can't deserialise to the class (json is using strongly typed classes to serialise to interface).

One way i though of was to deserialise the json to the poco in version 2.0.1.0 and then remap to version 2.0.2.0 and save to database.

So i followed this Using two DLLs with same name and same namespace

this didnt work fully as it was complaining about that the name already exists in the project requesting i either sign my assemly or remove it.

i then signed my assemblies using (brutal developer signing) using unsigned assemblies in signed ones. Though when it's signed is says delayed signing for some reason

this let me build with no errors. however now when i run and get to the class which is about to run the migration it fails with Fiel Load Exception Could not load file or assembly ........... The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)

So any ideas how i can solve this problem? i've been on a hunt the for 2 days looking through forums and posts

c#
wpf
visual-studio
dll
asked on Stack Overflow Jul 31, 2020 by UndeadEmo

0 Answers

Nobody has answered this question yet.


User contributions licensed under CC BY-SA 3.0