title: C++ UUID to stl string
body: <p>Trying to convert a UUID to string without boost. I have the following but assigning the wszUuid to the string guid doesn't work. Anyone know how I can do this so I can return a stl string?</p>
  
  <pre><code>string Server::GetNewGUID()
  {
      UUID uuid;
      ::ZeroMemory(&amp;uuid, sizeof(UUID));
  
      // Create uuid or load from a string by UuidFromString() function
      ::UuidCreate(&amp;uuid);
  
      // If you want to convert uuid to string, use UuidToString() function
      WCHAR* wszUuid = NULL;
      ::UuidToStringW(&amp;uuid, (RPC_WSTR*)&amp;wszUuid);
      if (wszUuid != NULL)
      {
          ::RpcStringFree((RPC_CSTR*)&amp;wszUuid);
          wszUuid = NULL;
      }
  
      string guid; 
      guid = wszUuid;            // ERROR: no operator "=" matches these operands operand types are: std::string = WCHAR*
  
      return guid;
  }
  </code></pre>