且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

将DLL合并到EXE?

更新时间:2023-02-18 13:39:30

对于.NET Framework 4.5

  ILMerge.exe / target:winexe / targetplatform:v4,C:\Program Files\Reference Assemblies\Microsoft\Framework\\ \\ NETFramework\v4.0/out:finish.exe insert1.exe我nsert2.dll 

ILMerge


  1. 打开CMD和cd到您的目录。让我们说: cd C:\test

  2. 插入上面的代码。

  3. code> /out:finish.exe 替换 finish.exe 与您想要的任何文件名。

  4. /out:finish.exe 后面,您必须将要
    的文件合并。


I have two DLL files which I'd like to include in my EXE file to make it easier to distribute it. I've read a bit here and there how to do this, even found a good thread here, and here, but it's far too complicated for me and I need real basic instructions on how to do this.

I'm using Microsoft Visual C# Express 2010, and please excuse my "low standard" question, but I feel like I'm one or two level below everyone else's expercise :-/ If someone could point out how to merge these DDL files into my EXE in a step-by-step guide, this would be really awesome!

For .NET Framework 4.5

ILMerge.exe /target:winexe /targetplatform:"v4,C:\Program Files\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.0" /out:finish.exe insert1.exe insert2.dll

ILMerge

  1. Open CMD and cd to your directory. Let's say: cd C:\test
  2. Insert the above code.
  3. /out:finish.exe replace finish.exe with any filename you want.
  4. Behind the /out:finish.exe you have to give the files you want to be combined.