2012-03-23 53 views
2

感謝您花費一些時間幫助我。 使用:微軟的Visual C#2010速成ILMerge有點失落

我有兩個文件:RJFCModPackInstaller.exe和Ionic.Zip.dll,我想在合併到一個:RJFCModpackInstaller.exe

我試着做後期構建並擁有多個GUI,我可以做什麼?

我嘗試使用這樣的:

"$(SolutionDir)ILMerge\ILMerge.exe" /out:"$(SolutionDir)\deploy\$(TargetFileName)" "$(TargetDir)$(TargetFileName)" "$(TargetDir)*.dll" /target:exe /targetplatform:'v4, C:\Windows\Microsoft.NET\Framework64\v4.0.30319' /wildcards 

但這個錯誤就出來了:

Error 2 The command ""C:\Users\FusionD\documents\visual studio 2010\Projects\RJFCModPackInstaller\ILMerge\ILMerge.exe" /out:"C:\Users\FusionD\documents\visual studio 2010\Projects\RJFCModPackInstaller\\deploy\RJFCModPackInstaller.exe" "C:\Users\FusionD\documents\visual studio 2010\Projects\RJFCModPackInstaller\RJFCModPackInstaller\bin\Release\RJFCModPackInstaller.exe" "C:\Users\FusionD\documents\visual studio 2010\Projects\RJFCModPackInstaller\RJFCModPackInstaller\bin\Release\*.dll" /target:exe /targetplatform:'v4, C:\Windows\Microsoft.NET\Framework64\v4.0.30319' /wildcards" exited with code 3. RJFCModPackInstaller 

編輯: 如果我的代碼更改爲:

C:\Program Files (x86)\Microsoft\ILMerge\ILMerge.exe /out:"$(SolutionDir)deploy\$(TargetFileName)" "$(TargetDir)$(TargetFileName)" "$(TargetDir)*.dll" /target:exe /targetplatform:'v4, C:\Windows\Microsoft.NET\Framework64\v4.0.30319' /wildcards 

我獲得錯誤9009:

Error 1 The command "C:\Program Files (x86)\Microsoft\ILMerge\ILMerge.exe /out:"C:\Users\FusionD\documents\visual studio 2010\Projects\RJFCModPackInstaller\deploy\RJFCModPackInstaller.exe" "C:\Users\FusionD\documents\visual studio 2010\Projects\RJFCModPackInstaller\RJFCModPackInstaller\bin\Debug\RJFCModPackInstaller.exe" "C:\Users\FusionD\documents\visual studio 2010\Projects\RJFCModPackInstaller\RJFCModPackInstaller\bin\Debug\*.dll" /target:exe /targetplatform:'v4, C:\Windows\Microsoft.NET\Framework64\v4.0.30319' /wildcards" exited with code 9009. RJFCModPackInstaller 
+1

Windows錯誤代碼3是「系統找不到指定的路徑」。或者ERROR_PATH_NOT_FOUND。這表示路徑有問題,而不是文件名。 – 2012-03-23 07:33:30

+0

雅2010抱歉。我很可笑,哈哈。必須弄清楚這一點! – Chris 2012-03-23 07:39:53

回答

4

有一個額外的\這裏:

/out:"C:\Users\FusionD\documents\visual studio 2010\Projects\RJFCModPackInstaller\\deploy 
                         ^
                          | 

所以我建議改變

$(SolutionDir)\deploy 

$(SolutionDir)deploy 

的9009錯誤是becau你現在已經從命令中刪除了引號(所以它試圖執行C:\Program)。把這些引號放回去(或者回復原來的命令,沒有額外的\)。

+0

嗯,我不認爲這是...但謝謝! – Chris 2012-03-23 07:52:12

+1

@Chris - 查看更新的答案。 – 2012-03-23 08:02:48

+0

謝謝!另外:我感覺遲鈍。 – Chris 2012-03-23 08:07:19