CXTButton,CXTFlatComboBox and ATL |
Post Reply |
Author | |
moricg
Newbie Joined: 28 April 2005 Location: Israel Status: Offline Points: 2 |
Post Options
Thanks(0)
Posted: 28 April 2005 at 3:45pm |
I am trying to dynamically create a control of the CXTButton class in my ATL application with MFC support.I get a CWnd object from m_hWnd by using CWnd::FromHandle(m_hWnd) to get a temporary MFC CWnd pointer and pass it on to Create function as a parent window handler . It is really works until I set any style for button. Ex.: m_ctlBtnStart.SetXButtonStyle(BS_XT_SEMIFLAT | BS_XT_SHOWFOCUS); So I can not see button on its place ( it is turn be invisible ) ,but I can click on the "button". The same problem I have with CXTFlatComboBox. After m_ctlComboHost.DisableFlatLook( true); part of control looks incorrect.Can anybody help me? Thanks, Moritz Goldshtein. |
|
Oleg
Admin Group Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
Post Options
Thanks(0)
|
You must Subclass it and not just call CWnd::FromHandle(m_hWnd)
|
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
moricg
Newbie Joined: 28 April 2005 Location: Israel Status: Offline Points: 2 |
Post Options
Thanks(0)
|
I'm do it. It is not works. Function DrawItem of CXTButton is not been called in this case. |
|
Post Reply | |
Tweet
|
Forum Jump | Forum Permissions You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |