문제

I would like to convert a argv to wstring.

I tried

int _tmain(int argc, _TCHAR* argv[])
{
    wstring sStartDir=L"";

    if (argc==1)
    {
            //no params given
    }
    else
    {
        sStartDir=argv[1];
    }

but the compiler said "No = operator compatible with this operand".

Thank you.

도움이 되었습니까?

해결책

I changed the language set to "Use unicode", and now it works.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top