내가 오류를 CString을 사용하여 링커 오류를 받고 있어요입니다링크 오류 CString을
class CConfiguration
{
private:
static CString _campaignFolderPath;
public:
static void Read();
private:
CConfiguration(void);
~CConfiguration(void);
};
그 읽기 방법은 다음과 같이 정의된다 :
error LNK2001: unresolved external symbol "private: static class ATL::CStringT<wchar_t,class StrTraitMFC<wchar_t,class ATL::ChTraitsCRT<wchar_t> > > CConfiguration::_campaignFolderPath" ([email protected]@@[email protected][email protected][email protected][email protected]@@@@@[email protected]@A)
I는 다음과 같이 정의 된 클래스가
void CConfiguration::Read()
{
CConfigFile configReader(_T("Config.ini"));
TCHAR temp[1024];
configReader.GetStringValue(_T("Campaigns"), _T("CampaignsFolderPath"), temp);
_campaignFolderPath = temp;
}
오류의 원인에 대한 단서가 있습니까? Visual Studio 2008을 사용하고 있습니다.
오류 C2039 : 'CString': 'CConfiguration'의 구성원이 아닙니다. – akif
CString CConfiguration :: _ campaignFolderPath; 감사합니다 – akif
대답을 편집하십시오 제발, 그 오타를 믿지 – akif