Hi
I have a host window. on top of that host window i create an tab control. this is done by calling Create function. for example
Class A : public CComObjectRootEx<CComMultiThreadModel>,
public CComCoClass<CSchOrderDlg, &CLSID_SchOrderDlg>,
public ISupportErrorInfo,
public IConnectionPointContainerImpl<CSchOrderDlg>,
public IDispatchImpl<ISchOrderDlg, &IID_ISchOrderDlg, &LIBID_SCHORDERSLib>,
public CDialogImpl<CSchOrderDlg>,
public _ISchEventOrdersEvents,
public CProxy_ISchOrderDlgEvents<CSchOrderDlg>
{
CContainedWindow m_bContain;
LRESULT Func( UINT uMSg, WPARAM wParam, LPARAm lParam, BOOL &bHandled)
Begin_msg_map(A)
ALT_MSG_MAP (1)
Message_Handler(WM_ERASEBAKGRND, Func)
END_MSG_MAP()
}
The above code is in .h file.
In .cpp file for this in constructor i give m_bContain(_T("SYS TAbControl"),this,1)
down the line i create
m_bContain.Create(....)
now i am not able to change the background color of the contained window.
any thoughts how to proceed?
One option i tried is to subclass CContainedWindow
Class B ::CContainedWindow and where ever i am using CContained window i am using B and have declared message maps within this class. but still this did not work.
Please let me know how to solve this
I have a host window. on top of that host window i create an tab control. this is done by calling Create function. for example
Class A : public CComObjectRootEx<CComMultiThreadModel>,
public CComCoClass<CSchOrderDlg, &CLSID_SchOrderDlg>,
public ISupportErrorInfo,
public IConnectionPointContainerImpl<CSchOrderDlg>,
public IDispatchImpl<ISchOrderDlg, &IID_ISchOrderDlg, &LIBID_SCHORDERSLib>,
public CDialogImpl<CSchOrderDlg>,
public _ISchEventOrdersEvents,
public CProxy_ISchOrderDlgEvents<CSchOrderDlg>
{
CContainedWindow m_bContain;
LRESULT Func( UINT uMSg, WPARAM wParam, LPARAm lParam, BOOL &bHandled)
Begin_msg_map(A)
ALT_MSG_MAP (1)
Message_Handler(WM_ERASEBAKGRND, Func)
END_MSG_MAP()
}
The above code is in .h file.
In .cpp file for this in constructor i give m_bContain(_T("SYS TAbControl"),this,1)
down the line i create
m_bContain.Create(....)
now i am not able to change the background color of the contained window.
any thoughts how to proceed?
One option i tried is to subclass CContainedWindow
Class B ::CContainedWindow and where ever i am using CContained window i am using B and have declared message maps within this class. but still this did not work.
Please let me know how to solve this