2012-06-14 2 views
6

클래스 라이브러리 (ProjectA)와 두 개의 Sharepoint 프로젝트 (ProjectB & ProjectC)가 포함 된 Visual Studio 2010 솔루션이 있습니다. 종속성 순서는 ProjectB 참조입니다. ProejctA와 ProjectC는 모두 ProjectA & ProjectB를 참조합니다. 내가 시도어셈블리 바인딩 오류 : 바인드 결과 : hr = 0x80070002. 지정한 파일을 찾을 수 없습니다.

* Assembly Binder Log Entry (14/06/2012 @ 09:38:32) *

The operation failed.

Bind result: hr = 0x80070002. The system cannot find the file specified.

Assembly manager loaded from: C:\Windows\Microsoft.NET\Framework\v4.0.30319\clr.dll

Running under executable C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\devenv.exe

--- A detailed error log follows.

=== Pre-bind state information === LOG: User = DOMAIN\username

LOG: DisplayName = ProjectB, Version=0.0.0.0, Culture=neutral, PublicKeyToken=aaaaaaaaaaaaaaaa, processorArchitecture=MSIL (Fully-specified)

LOG: Appbase = file:///C:/Program Files (x86)/Microsoft Visual Studio 10.0/Common7/IDE/

LOG: Initial PrivatePath = NULL

LOG: Dynamic Base = NULL

LOG: Cache Base = NULL

LOG: AppName = devenv.exe

Calling assembly : (Unknown).

LOG: This bind starts in default load context.

LOG: Using application configuration file: C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\devenv.exe.Config

LOG: Using host configuration file:

LOG: Using machine configuration file from C:\Windows\Microsoft.NET\Framework\v4.0.30319\config\machine.config.

LOG: Post-policy reference: ProjectB, Version=0.0.0.0, Culture=neutral, PublicKeyToken=aaaaaaaaaaaaaaaa, processorArchitecture=MSIL

LOG: GAC Lookup was unsuccessful.

LOG: Attempting download of new URL file:///C:/Program Files (x86)/Microsoft Visual Studio 10.0/Common7/IDE/ProjectB.DLL. LOG: Attempting download of new URL file:///C:/Program Files (x86)/Microsoft Visual Studio 10.0/Common7/IDE/ProjectB/ProjectB.DLL. LOG: Attempting download of new URL file:///C:/Program Files (x86)/Microsoft Visual Studio 10.0/Common7/IDE/PublicAssemblies/ProjectB.DLL. LOG: Attempting download of new URL file:///C:/Program Files (x86)/Microsoft Visual Studio 10.0/Common7/IDE/PublicAssemblies/ProjectB/ProjectB.DLL. LOG: Attempting download of new URL file:///C:/Program Files (x86)/Microsoft Visual Studio 10.0/Common7/IDE/PrivateAssemblies/ProjectB.DLL. LOG: Attempting download of new URL file:///C:/Program Files (x86)/Microsoft Visual Studio 10.0/Common7/IDE/PrivateAssemblies/ProjectB/ProjectB.DLL. LOG: Attempting download of new URL file:///C:/Program Files (x86)/Microsoft Visual Studio 10.0/Common7/IDE/CommonExtensions/Microsoft/TemplateProviders/ProjectB.DLL. LOG: Attempting download of new URL file:///C:/Program Files (x86)/Microsoft Visual Studio 10.0/Common7/IDE/CommonExtensions/Microsoft/TemplateProviders/ProjectB/ProjectB.DLL. LOG: Attempting download of new URL file:///C:/Program Files (x86)/Microsoft Visual Studio 10.0/Common7/IDE/PrivateAssemblies/DataCollectors/ProjectB.DLL. LOG: Attempting download of new URL file:///C:/Program Files (x86)/Microsoft Visual Studio 10.0/Common7/IDE/PrivateAssemblies/DataCollectors/ProjectB/ProjectB.DLL. LOG: Attempting download of new URL file:///C:/Program Files (x86)/Microsoft Visual Studio 10.0/Common7/IDE/PrivateAssemblies/DataCollectors/x86/ProjectB.DLL. LOG: Attempting download of new URL file:///C:/Program Files (x86)/Microsoft Visual Studio 10.0/Common7/IDE/PrivateAssemblies/DataCollectors/x86/ProjectB/ProjectB.DLL. LOG: Attempting download of new URL file:///C:/Program Files (x86)/Microsoft Visual Studio 10.0/Common7/IDE/CommonExtensions/Microsoft/Editor/ProjectB.DLL. LOG: Attempting download of new URL file:///C:/Program Files (x86)/Microsoft Visual Studio 10.0/Common7/IDE/CommonExtensions/Microsoft/Editor/ProjectB/ProjectB.DLL. LOG: Attempting download of new URL file:///C:/Program Files (x86)/Microsoft Visual Studio 10.0/Common7/IDE/CommonExtensions/Platform/Debugger/ProjectB.DLL. LOG: Attempting download of new URL file:///C:/Program Files (x86)/Microsoft Visual Studio 10.0/Common7/IDE/CommonExtensions/Platform/Debugger/ProjectB/ProjectB.DLL. LOG: Attempting download of new URL file:///C:/Program Files (x86)/Microsoft Visual Studio 10.0/Common7/IDE/ProjectB.EXE. LOG: Attempting download of new URL file:///C:/Program Files (x86)/Microsoft Visual Studio 10.0/Common7/IDE/ProjectB/ProjectB.EXE. LOG: Attempting download of new URL file:///C:/Program Files (x86)/Microsoft Visual Studio 10.0/Common7/IDE/PublicAssemblies/ProjectB.EXE. LOG: Attempting download of new URL file:///C:/Program Files (x86)/Microsoft Visual Studio 10.0/Common7/IDE/PublicAssemblies/ProjectB/ProjectB.EXE. LOG: Attempting download of new URL file:///C:/Program Files (x86)/Microsoft Visual Studio 10.0/Common7/IDE/PrivateAssemblies/ProjectB.EXE. LOG: Attempting download of new URL file:///C:/Program Files (x86)/Microsoft Visual Studio 10.0/Common7/IDE/PrivateAssemblies/ProjectB/ProjectB.EXE. LOG: Attempting download of new URL file:///C:/Program Files (x86)/Microsoft Visual Studio 10.0/Common7/IDE/CommonExtensions/Microsoft/TemplateProviders/ProjectB.EXE. LOG: Attempting download of new URL file:///C:/Program Files (x86)/Microsoft Visual Studio 10.0/Common7/IDE/CommonExtensions/Microsoft/TemplateProviders/ProjectB/ProjectB.EXE. LOG: Attempting download of new URL file:///C:/Program Files (x86)/Microsoft Visual Studio 10.0/Common7/IDE/PrivateAssemblies/DataCollectors/ProjectB.EXE. LOG: Attempting download of new URL file:///C:/Program Files (x86)/Microsoft Visual Studio 10.0/Common7/IDE/PrivateAssemblies/DataCollectors/ProjectB/ProjectB.EXE. LOG: Attempting download of new URL file:///C:/Program Files (x86)/Microsoft Visual Studio 10.0/Common7/IDE/PrivateAssemblies/DataCollectors/x86/ProjectB.EXE. LOG: Attempting download of new URL file:///C:/Program Files (x86)/Microsoft Visual Studio 10.0/Common7/IDE/PrivateAssemblies/DataCollectors/x86/ProjectB/ProjectB.EXE. LOG: Attempting download of new URL file:///C:/Program Files (x86)/Microsoft Visual Studio 10.0/Common7/IDE/CommonExtensions/Microsoft/Editor/ProjectB.EXE. LOG: Attempting download of new URL file:///C:/Program Files (x86)/Microsoft Visual Studio 10.0/Common7/IDE/CommonExtensions/Microsoft/Editor/ProjectB/ProjectB.EXE. LOG: Attempting download of new URL file:///C:/Program Files (x86)/Microsoft Visual Studio 10.0/Common7/IDE/CommonExtensions/Platform/Debugger/ProjectB.EXE. LOG: Attempting download of new URL file:///C:/Program Files (x86)/Microsoft Visual Studio 10.0/Common7/IDE/CommonExtensions/Platform/Debugger/ProjectB/ProjectB.EXE. LOG: All probing URLs attempted and failed.

:

Compilation failed. Unable to load one or more of the requested types. Retrieve the LoaderExceptions property for more information.

융합 로그에보고 내가 다음과 같은 오류를 지적 :

은 하나의 특정 개발 컴퓨터에 내가 ProjectC를 만들려고 다음과 같은 오류가 발생합니다 :

  1. ProjectB에 대한 참조를 제거하고 다시 추가하십시오 :
    • A) projectB의 debug 폴더에 직접 수동 기준으로 프로젝트 참조
    • B)와 같은 수동으로 "로컬 복사"를 변경 GAC
    • 에 ProjectB.dll을 배치
  2. 옵션을 True에서 False로 설정하고 다시 True로 설정

(2) 어셈블리를 GAC에 배치하면 ProjectC에서 빌드 할 수 있습니다. 조립품을 찾지 못하는 이유는 무엇입니까 (다른 기계에서도 마찬가지입니까)?

+0

을하는 기계 64 비트 또는 그냥이 일의 모든? –

+0

모두가 64 비트 Windows Server 2008 R2 – mundeep

답변

3

는 그래서 어셈블리 우리가 Delayed Signing the Assemblies이기 때문에이 것을 의미했다 찾을 수 없습니다 이유를 밝혀 신속한. 또한 Visual Studio 명령 프롬프트의 x86 버전에서 x86 용으로 건너 뛰는 확인을 추가해야했습니다. 내가 테스트 어셈블리 중 하나를 다음과 같은 예외가 언급 한 특정 명령 기반의 빌드/배포 스크립트를 시도하기 때문에

내가에만이를 찾기 위해 관리 :

Could not load file or assembly 'ProjectC.Tests, Version=0.0.0.0, Culture=neutral, PublicKeyToken=e72f8d3506b83180' or one of its dependencies. Strong name validation failed. (Exception from HRESULT: 0x8013141A)

3

PublicKeyToken = aaaaaaaaaaaaaaaa가 다를 수 있으며 버전 번호가 다를 수 있습니다. 나는 당신이 설명한대로 Fusion Log Viewer to Debug을 사용해야한다고 생각하고 당신이 당신의 문제를 완전히 해결하기를 희망합니다.

Because the assembly does not have a valid strong name signature, the verification of that signature must be turned off. You can do this by using the –Vr option with the Strong Name tool.

이미 그러나 만 64 비주얼 스튜디오 명령에 필요한 모든 공개 키에 대한 이런 짓을했다 :

+1

입니다. a) 퓨전 로그는 GAC를 확인한 다음 프로젝트 빈 폴더 대신 IDE 폴더를 확인한다는 것보다 위에 있습니다. (b) 수동으로 ProjectB 어셈블리를 GAC에 넣으면 위에서 언급 한 것처럼 (이는 키가 정확함을 의미 함) - 나는 수동으로 (sn -T)를 체크하고 키는 동일합니다. – mundeep

+0

(sn-T) 및 어셈블리의 버전 번호를 사용하여 검사 한 키를 붙여 넣을 수 있습니까? – MMK

+0

그래서 GAC에서 ProjectB dll을 제거했고 다시 빌드하려고 시도했지만 다음과 같이 융합되었습니다. === 사전 바인드 상태 정보 === LOG : 사용자 = DOMAIN \ username LOG : DisplayName = ProjectB, Version = 0.0.0.0, 문화 = 중립, PublicKeyToken = e72f8d3506b83180, processorArchitecture = MSIL 로그 : Appbase = file : /// C :/Program Files (x86)/Microsoft Visual Studio 10.0/Common7/IDE/ .. ... LOG : 정책 이후 참조 : ProjectB, 버전 = 0.0.0.0, Culture = 중립, PublicKeyToken = e72f8d3506b83180, processorArchitecture = MSIL LOG : GAC 조회가 실패했습니다. – mundeep

관련 문제