title: C++ get the length of LPCWSTR and LPVOID
body: <p>The winapi function <a href="http://msdn.microsoft.com/en-us/library/windows/desktop/aa384110%28v=vs.85%29.aspx" rel="nofollow">WinHttpSendRequest()</a> wants the size of the second parameter in the third one and the size of the fourth parameter in the fifth one.<br>
  How can I calculate it?<br>
  I have a function wrapped around it and I pass the strings directly, about like this:  </p>
  
  <pre><code>void Req(LPCWSTR headers, LPVOID body) {
      WinHttpSendRequest( hRequest, headers, (DWORD)strlen(headers), body, (DWORD)strlen(body), 0, 0 );
  }
  Req(L"User-Agent: blabla/1.0\r\nConnection: Keep Alive", "asdf=qwer&amp;abcd=1234);
  </code></pre>
  
  <p>The above code doesn't work. :/<br>
  I hope you can help me out.</p>