I have the following function in C++:
std::wstring decToDeg(double input)
{
    int deg, min;
    double sec, sec_all, min_all;
    std::wstring output;
    sec_all = input * 3600;
    sec = Math::Round(static_cast<int>(sec_all) % 60, 3); //code from @spin_eight answer
    min_all = (sec_all - sec) / 60;
    min = static_cast<int>(min_all) % 60;
    deg = static_cast<int>(min_all - min) / 60;
    output = deg + L"º " + min + L"' " + sec + L"\"";
    return output;
}
When I try to compile I get this error:
error C2679: binary '=' : no operator found which takes a right-hand operand of type 'System::String ^' (or there is no acceptable conversion)  
What can I do to correct these two errors in my function?
EDIT: solved
std::wstring decToDeg(double input)
{
    int deg, min;
    double sec, sec_all, min_all;
    sec_all = input * 3600;
    sec = Math::Round(static_cast<int>(sec_all) % 60, 3);
    min_all = (sec_all - sec) / 60;
    min = static_cast<int>(min_all) % 60;
    deg = static_cast<int>(min_all - min) / 60;
    std::wostringstream output;
    output << deg << L"º " << min << L"' " << sec << L"\"";
    return output.str();
}
 
     
     
     
     
    