<span>Hm, okay. I just wanted to test the waters here; I&#39;ll rework this to use a function that loads<br>a string from a resource file. Does the help message itself look okay? I just used the message<br>provided by the native dxdiag app, but I could rework it if there are issues with copyright or<br>
wine conventions.<br><br>On Thu, Sep 17, 2009 at 6:34 AM, Henri Verbeet &lt;</span><a href="http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=25500104&amp;i=0" target="_top" rel="nofollow"><span>hverbeet@...</span></a><span>&gt; wrote:
</span><div style="height: auto; overflow-y: auto;" class="shrinkable-quote"><br><span>&gt; 2009/9/17 Brian Nguyen &lt;</span><a href="http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=25500104&amp;i=1" target="_top" rel="nofollow"><span><b class="highlight">mtxcoll</b>@...</span></a><span>&gt;:
</span><br><span>&gt;&gt; +/* Thread-safe function for converting to wide char strings at runtime */
</span><br><span>&gt;&gt; +LPWSTR PrintWide(LPWSTR buf, size_t len, const char *s)
</span><br><span>&gt;&gt; +{
</span><br><span>&gt;&gt; + � �size_t i;
</span><br><span>&gt;&gt; + � �for (i = 0; i &lt; len &amp;&amp; *s != &#39;\0&#39;; i++, s++) {
</span><br><span>&gt;&gt; + � � � �buf[i] = *s;
</span><br><span>&gt;&gt; + � �}
</span><br><span>&gt;&gt; + � �return buf;
</span><br><span>&gt;&gt; +}
</span><br><span>&gt; That doesn&#39;t do what you want, you should use MultiByteToWideChar() to
</span><br><span>&gt; convert to WCHAR. However, I don&#39;t think you want to hardcode the
</span><br><span>&gt; strings in the first place, you should load them from the resources so
</span><br><span>&gt; they can be translated. Also, functions like that which are only used
</span><br><span>&gt; in the current file should be static.
</span></div><br><span>Thanks for taking this on!
</span><br><br><span>-- 
</span><br><span>-Austin
</span><br clear="all"><br>-- <br>Brian Nguyen<br><a href="mailto:mtxcoll@gmail.com">mtxcoll@gmail.com</a><br>