Archived

This topic is now archived and is closed to further replies.

WM_CHAR??? HELP!!!

This topic is 5313 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

ok im new to using opengl and i wanted to have my program take in a string and then display it....very simple...how would i go about doing this...i know i have to use WM_CHAR but could someone give an example how to write and use it for this purpose...im very confused about this and any help would be greatly appreciated

Share this post


Link to post
Share on other sites
You could use

bool keys[256]; // Given: Data structure for holding key input

case WM_CHAR:
keys[wParam] = true;
break;


though i would prefer...


bool keys[256]; // Given: Data structure for holding key input

case WM_KEYDOWN:
keys[wParam] = true;
break;
case WM_KEYUP:
keys[wParam] = false;
break;


EDIT:
Ok, seeing as how i wasn't paying attention to what you were asking...

look up