Jump to content
  • Advertisement
Sign in to follow this  
RedKMan

WIN C++ Combo box problem

This topic is 4068 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I'm working on a program which retrieves the graphics adapter name and displays it in a combo box. I'm using the Unicode character set so I've had to WCHAR some vars from char. I've ended up with a lot of garbage text. Obviously this is indicating some sort of problem using Unicode. Just wondering if it's a straight forward problem. It's kind of hard to post the code because there are DLL's involced and very large DX enumeration classes. I've spent a few days looking through it all and wouldn't wish it on anyone else.

Share this post


Link to post
Share on other sites
Advertisement
You need to show some code:

Is the whole project set to unicode or is it just the enumeration functions using unicode? How do you create the combo box and add the strings?

If it's the latter consider using the CreateWindow(Ex)W function for the combo box directly instead of relying on the macro. This will create the combo with Unicode and therefore also treats every string as Unicode.

Or you can use WideCharToMultiByte to modify the string.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!