• Advertisement

Archived

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

Can't use classes to create a window!

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

Hey, I''m building a map editor in win32, and everything is going along fine building it in C with a very procedural style. But, when I try to switch over to using classes I run into a big problem. Inside my WndProc, I need to access information that lies inside the window class. So far this has been impossible. Because the the proc is its own function, it can''t have access to the instance of the window class that i create in WinMain, and the only other way I can think of giving it access is by making it part of the class, which the compiler doesn''t like to much. This is the error i get when its part of the class... cannot convert from ''long (__stdcall CMainFrame::*)(struct HWND__ *,unsigned int,unsigned int,long)'' to ''long (__stdcall *) (struct HWND__ *,unsigned int,unsigned int,long)'' thanks for any help

Share this post


Link to post
Share on other sites
Advertisement

  • Advertisement