Dotpeek - Modify DLL Files - Use modified(recompiled) in project

6.4k Views Asked by At

I already did the process - Importing dll file in Dotpeek and Exporting Assembly to Project, Now I can modify dll file in VS 2015, but how to recompile the project and use recompiled dll file again in existing project.. I tried with building project in vs 2015 but it displays lots of compile time errors, Please help

Thanks :)

2

There are 2 best solutions below

2
TsviatkoYov On

Rather unfortunately, there is no decompiler that will produce code that compiles for an assembly containing more than a couple of classes.

So you might want to try JustDecompile + Reflexil to do your edit. The advantage of this approach is that only the part you edit will get changed and the rest of the assembly will remain the same as original.

0
Mohd Ilyas On

You can use dotPeek of Jetbrains, can open any DLL with it by just right-clicking the DLL and Open with dotPeek.

Once DLL is de-compile in dotPeek, right-click click on the DLL in the left sectoin and chose the option Export to Project.

It will open the entire DLL as a Class Library Project in Visual Studio in the case of .NET DLL.

You can modify the source code and recompile the DLLs.

I am not very sure about your requirement, I would advise you to Extend the DLLs method/operation into your project rather than doing an edit on the recompile on the DLL.