0
votes

I have a C# project that uses a third-party library which depends on old version DevExpress. There is a bug in a dll(DevExpress.Utils.v9.2.dll) of this version DevExpress. I use .NET Reflector and Reflexil to patch the dll and use the patched dll replace the old one. Then when I rebuild solution, Visual Studio shows me error:

Error CS0012 The type 'XtraForm' is defined in an assembly that is not referenced. You must add a reference to assembly 'DevExpress.Utils.v9.2, Version=9.2.6.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a'.

It seems original dll is signed that causes the problem. I have tried removing strong name but it does not work. How to resolve?

2
Can you derive a class from original XtraForm, fix the bug there, and reference new dll (which references Devexpress' dll)Marko Juvančič
If you had a valid license at the time the DevExpress XtraEditors v9.2 assembly was produced you will still have access to download it. There is likely a minor version upgrade to which you would still have access that may have a fix to the bug you are encountering. Trying to rebuild the signed assemblies after decompililng them may be a violation of the DevExpress end-user license agreement (EULA) as well: devexpress.com/Support/EULAs/winforms-controls.xmlBrendon
@Brendon, According to this post, the bug is fixed in version 10.1.8.AlpacaMan
Frankly I think your only option would be to upgrade to that version. If you had a license for v9.2 that included source code, you could modify that yourself and provide it to DevExpress, who will digitally sign it for you. I don't believe they will do that with a decompiled source however.Brendon

2 Answers

0
votes

Use the awesome alternative to ILSpy and friends: dnSpy.

dnSpy

0
votes

The problem is that other assemblies reference the signed DevExpress.Utils.v9.2.dll. After patching, the dll is unsinged so it does not work. I solve the problem myself by adding referencing assemblies to update and removing strong name and updating referencing assemblies using Strong Name Remover bundled with Reflexil.

enter image description here