I am calling a function which requires a HWND in the parameter. The function is being called from the view class. How can I obtain the HWND from the view class?
All classes derived from CWnd can be have operator HWND. Try to use theirs class name instead of handle. If it is not working, try something as GetHandle(..) or Handle(), I don't know exactly John Fill
Two possibilities:
1.GetSafeHwnd() is a function of CWnd class. CView is a CWnd derived class so you can use it.
2.Use m_hWnd member of the CWnd derived class.
If you will need to get a pointer from a handle consifder the function FromHandle.
Hope this helps,s-) Blessed is he who in the name of justice and good will, shepards the week through the valley of darknees...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.