during the window's initialization, use the control's Create function, in which you specify the parent HWND, RECT containing the location and height, and the control's ID, among other things. The instance object of the control must NOT be local to a function, but global in the c++ class or program file in which it is used because it must stay in scope during the lifetime of the window.
Sponsor
Team Colleague
Featured Poster
Reputation Points: 5608
Solved Threads: 2282
Retired and Enjoying Life
Offline 21,957 posts
since Aug 2005