I have following code:
Tools::Logger.Log(string(GetLastError()), Error);
GetLastError() returns a DWORD a numeric
GetLastError()
DWORD
Use std::stringstream.
std::stringstream errorStream; errorStream << GetLastError(); Tools::Logger.Log(errorStream.str(), Error);