title: convert std::string to const tchar*
body: <p>I have a function that takes in a parameter called arrayOfStrings defined as below:</p>
  
  <pre><code>const TCHAR* arrayOfStrings[] = { L"Test" };
  </code></pre>
  
  <p>Now I would like to convert strings to the type above, but I don't know how. <a href="https://stackoverflow.com/questions/20454793/converting-string-to-tchar-in-vc">This link</a> provides a solution for converting string to tchar, but not const tchar*. <a href="http://www.cplusplus.com/forum/general/12245/" rel="nofollow noreferrer">This other link</a> shows how to convert string to tchar*, but not const tchar*, and the memory allocation is a problem for me with this second solution. As you can probably tell, I am very new to c++, so any educational tips would be appreciated as well.</p>