Exclude assembly
I am using Dropbox.Api in my project, which doesn't let me obfuscate my code
[ERROR] Failed to resolve dependency of 'MyApp.exe'. Exception: dnlib.DotNet.AssemblyResolveException: Could not resolve assembly: Dropbox.Api, Version=4.0.0.0, Culture=neutral, PublicKeyToken=310f0e82fbb45d01 at dnlib.DotNet.Extensions.ResolveThrow(IAssemblyResolver self, IAssembly assembly, ModuleDef sourceModule) in E:\Source\Public\Confuser2\dnlib\src\DotNet\IAssemblyResolver.cs:line 113 at Confuser.Core.ConfuserEngine.Inspection(ConfuserContext context) in e:\Source\Public\Confuser2\Confuser.Core\ConfuserEngine.cs:line 264
I tried to exclude the assembly by adding the following line in AssemblyInfo.cs:
[assembly: Obfuscation(Exclude = false, Feature = "namespace ('Dropbox.Api'):-rename")]
but it did not help.
Am I doing something wrong?
You can't exclude a needed referenced assembly.
To solve your issue simply put Dropbox.Api.dll v4.0 in the same folder as where your main .exe file is :)