Original Post
Here''s the code I''m having problems with.
LPPOINT cursorPosition;
GetCursorPos(cursorPosition);
itoa(cursorPosition->x, holder1, 10);
TextOut (hDC, 430, 450, holder1, strlen(holder1));
I''m doing this to print out the X position of the mouse cursor. Assuming that all of the rest of the variables (holder1, hDc, etc) are all valid and that I have locked so I can mess directly with the surface, why won''t it work. The problem is specifically on the itoa function. It gives me an error when I try to access the cursorPosition->x variable. I have put other varibles in there and the code works fine. I think the error is somewhere in how I''m using the GetCursorPos() function. Any ideas? Thanks.
--Vic--