Visual Studio 2008에서 C++ 응용 프로그램을 작성하고 있습니다. 프로젝트에 Windows Form을 추가하고 CLR 지원을 활성화하고 양식을 인스턴스화하는 줄을 추가했습니다. 다음과 같이CLI 프로젝트 std :: basic_string
이 일 때문에, 나는 링커 오류의 부하를 얻을 :
오류 LNK2001 : 확인되지 않은 외부 기호 "공개 : 가상 클래스 표준 : : basic_string < 문자, 구조체 표준 : : char_traits < 문자> , 클래스 std :: allocator < char >> __thiscall ... "(...)
내가 뭘 잘못하고 있는거야?
전체 오류 (익명으로) : 당신이 통근 등의 변수를 선언하지 않는 이상 한 번 이상 헤더 파일을 포함하고 있기 때문에
1>Linking...
1> Creating library C:\***.lib and object C:\***.exp
1>getProducts.obj : error LNK2001: unresolved external symbol "public: virtual class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > __thiscall ***::GetClassName(void)const " ([email protected]***@@[email protected][email protected]@[email protected]@[email protected]@[email protected]@[email protected]@XZ)
1>getProducts.obj : error LNK2001: unresolved external symbol "protected: virtual class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > __thiscall ***::GetClassName(void)const " ([email protected]***@@[email protected][email protected]@[email protected]@[email protected]@[email protected]@[email protected]@XZ)
1>getProducts.obj : error LNK2001: unresolved external symbol "protected: virtual class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > __thiscall ***::GetClassName(void)const " ([email protected]***@@[email protected][email protected]@[email protected]@[email protected]@[email protected]@[email protected]@XZ)
1>getProducts.obj : error LNK2001: unresolved external symbol "protected: virtual class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > __thiscall ***::GetClassName(void)const " ([email protected]***@@[email protected][email protected]@[email protected]@[email protected]@[email protected]@[email protected]@XZ)
1>getProducts.obj : error LNK2001: unresolved external symbol "protected: virtual class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > __thiscall ***::GetClassName(void)const " ([email protected]***@@[email protected][email protected]@[email protected]@[email protected]@[email protected]@[email protected]@XZ)
1>getProducts.obj : error LNK2001: unresolved external symbol "protected: virtual class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > __thiscall ***::GetClassName(void)const " ([email protected]***@@[email protected][email protected]@[email protected]@[email protected]@[email protected]@[email protected]@XZ)
1>getProducts.obj : error LNK2001: unresolved external symbol "protected: virtual class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > __thiscall ***::GetClassName(void)const " ([email protected]***@@[email protected][email protected]@[email protected]@[email protected]@[email protected]@[email protected]@XZ)
1>getProducts.obj : error LNK2001: unresolved external symbol "protected: virtual class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > __thiscall ***::GetClassName(void)const " ([email protected]***@@[email protected][email protected]@[email protected]@[email protected]@[email protected]@[email protected]@XZ)
1>MSVCRT.lib(crtexe.obj) : error LNK2019: unresolved external symbol _main referenced in function ___tmainCRTStartup
1>C:\***.exe : fatal error LNK1120: 9 unresolved externals
1>Build log was saved at "file://c:\***\BuildLog.htm"
1>getProducts - 10 error(s), 12 warning(s)
========== Rebuild All: 0 succeeded, 1 failed, 0 skipped ========
당신이 당신에게 라이브러리를 연결 했습니까? – Geoffroy
링크 라이브러리 디렉토리가 "예"로 설정되어 있습니다. 연결해야하는 특정 라이브러리가 있습니까? –
모르겠다. 나는 Visual Studio에서 일한 적이 없다. 전체 오류를 넣을 수 있습니까? – Geoffroy