我正在尝试做一个网页,您可以浏览文件夹。我已经在不同的解决方案做到了这一点,它的所有作品,但是当我试图把它与一个以上的项目谁也引用PostSharp解决方案集成我得到这个错误:System.IO.FileNotFoundException:无法加载文件或程序集。系统找不到该文件SharpSvn.dll
Unhandled exception (2.1.7.1, 32 bit, CLR 4.0, Release): System.IO.FileNotFoundException: Could not load file or assembly 'file:///C:\_projects\...\Libraries\SharpSvn\SharpSvn.dll' or one of its dependencies. The system cannot find the file specified.
File name: 'file:///C:\_projects\...\Libraries\SharpSvn\SharpSvn.dll'
at System.Reflection.RuntimeAssembly._nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, RuntimeAssembly locationHint, StackCrawlMark& stackMark, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)
at System.Reflection.RuntimeAssembly.nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, RuntimeAssembly locationHint, StackCrawlMark& stackMark, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)
at System.Reflection.RuntimeAssembly.InternalLoadAssemblyName(AssemblyName assemblyRef, Evidence assemblySecurity, StackCrawlMark& stackMark, Boolean forIntrospection, Boolean suppressSecurityChecks)
at System.Reflection.RuntimeAssembly.InternalLoadFrom(String assemblyFile, Evidence securityEvidence, Byte[] hashValue, AssemblyHashAlgorithm hashAlgorithm, Boolean forIntrospection, Boolean suppressSecurityChecks, StackCrawlMark& stackMark)
at System.Reflection.Assembly.ReflectionOnlyLoadFrom(String assemblyFile)
at PostSharp.Sdk.CodeModel.ModuleDeclaration.GetSystemModule()
at PostSharp.Sdk.CodeModel.Domain.LoadAssembly(Assembly reflectionAssembly, Boolean lazyLoading)
at PostSharp.Sdk.CodeModel.Domain.GetAssembly(IAssemblyName assemblyName, BindingOptions bindingOptions)
at PostSharp.Sdk.CodeModel.AssemblyRefDeclaration.GetAssemblyEnvelope()
at PostSharp.Sdk.Extensibility.Tasks.MulticastAttributeTask.^SgrhoGlQ(AssemblyRefDeclaration _0)
at PostSharp.Sdk.Extensibility.Tasks.MulticastAttributeTask.^+GwnKh4ZYHu3()
at PostSharp.Sdk.Extensibility.Tasks.MulticastAttributeTask.Execute()
at PostSharp.Sdk.Extensibility.Project.ExecutePhase(String phase)
at PostSharp.Sdk.Extensibility.Project.Execute()
at PostSharp.Hosting.PostSharpObject.ExecuteProjects()
at PostSharp.Hosting.PostSharpObject.InvokeProject(ProjectInvocation projectInvocation)
WRN: Assembly binding logging is turned OFF.
To enable assembly bind failure logging, set the registry value [HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1.
Note: There is some performance penalty associated with assembly bind failure logging.
To turn this feature off, remove the registry value [HKLM\Software\Microsoft\Fusion!EnableLog].
当我评论此方法的误差消失: 静态无效SVN_SSL_Override(对象发件人,SharpSvn.Security.SvnSslServerTrustEventArgs E) { e.AcceptedFailures = e.Failures; e.Save = true; } –
你检查过两个项目的目标平台是否一样? –
还要确保被引用的PostSharp的版本在所有项目中都是相同的。 – ohiodoug