Professional UI Solutions
Site Map   /  Register
 
 

Forum

Please Log In to post a new message or reply to an existing one. If you are not registered, please register.

NOTE: Some forums may be read-only if you are not currently subscribed to our technical support services.

Forums » Prof-UIS General Discussion » CExtTabMdiWnd bug with VS2008 Collapse All
Subject Author Date
Ulrich Heinicke May 22, 2010 - 1:10 AM

Hi,


there is a bug using CExtTabMdiWnd in VS2008 with the version 2.89. I have make an example with the wizard in VS2008. When i run the program i can’t seen any MDI-tab. Then i compile the same source with VS2005. There i can see the MDI-tab. I compile the dlls with the ingeration wizard without any changes. You can find the example under www.ibh-software.org/test.zip. Please tell me what’s wrong?


Thanks


Ulrich


 

Technical Support May 22, 2010 - 11:40 AM

Thank you for the test project. Here is how the MDI tabs control is created in it:

   if( !m_wndMdiTabs.Create(
                                    this, 
                                    CRect( 0, 0, 0, 0 ),
                                    UINT( IDC_STATIC ),
                                    WS_CHILD | WS_VISIBLE | WS_CLIPSIBLINGS,
                                    __ETWS_ORIENT_TOP
                                    |__ETWS_ENABLED_BTN_CLOSE
                                    |__ETWS_SHOW_BTN_CLOSE
                                    )
                                    //PUIS_TABWINDOWFROMDI - $$__PROFUISAPPWIZ_KEY_ADF_MDITABS$$
                        )

Everything looks like absolutely OK. The standard MFC’s IDC_STATIC constant is used as the dialog control identifier. This constant is the real source of the problem and that is why Prof-UIS uses its own __EXT_MFC_IDC_STATIC constant instead. Here is the technical information:

1) In Visual Studio 2005 and older versions you can use any constant as dialog control identifier of the control bar like window.

2) In Visual Studio 2008 and newer versions you can use any constant but not IDC_STATIC. The status bar like windows created using the IDC_STATIC constant as the dialog control identifier simply does not become repositioned by MFC.

Please replace the IDC_STATIC constant in the code snippet above with the __EXT_MFC_IDC_STATIC constant or any else.