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 Tech Support » Problem with Auto-Hide of DynamicControlBar Collapse All
Subject Author Date
Scott Moore Apr 2, 2009 - 2:41 PM

I’m having a problem with several dynamic control bars in my project.  They initially start out as a tabbed document.  When I switched them to docked, then I press the auto-hide button, I get the following assert in objcore.cpp:




CObject* AFX_CDECL AfxDynamicDownCast(CRuntimeClass* pClass, CObject* pObject)
{
    if (pObject != NULL && pObject->IsKindOf(pClass))
        return pObject;
    else
        return NULL;
}


>    mfc90ud.dll!CObject::IsKindOf(const CRuntimeClass * pClass=0x02670848)  Line 45 + 0x8 bytes    C++

     mfc90ud.dll!AfxDynamicDownCast(CRuntimeClass * pClass=0x02670848, CObject * pObject=0x03fcbb30)  Line 53 + 0x12 bytes    C++


-        pClass    0x02670848 {"CExtDynTabControlBar"}    CRuntimeClass *

+        m_lpszClassName    0x0265faf4 "CExtDynTabControlBar"    const char *

        m_nObjectSize    528    int

        m_wSchema    65535    unsigned int

        m_pfnCreateObject    0x01d98fe8    CObject * (void)*

        m_pfnGetBaseClass    0x01d8772f    CRuntimeClass * (void)*

+        m_pNextClass    0x00000000 {???}    CRuntimeClass *

+        m_pClassInit    0x00000000    const AFX_CLASSINIT *

-        pObject    0x03fcbb30 {CObject}    CObject *

+        __vfptr    0xfeeefeee    *

+        classCObject    {"CObject"}    CRuntimeClass


Any help would be greatly appreciated.

Technical Support Apr 3, 2009 - 10:44 AM

The call stack listing in your message tells that there was an attempt to access an incorrect pointer or damaged instance of a tabbed container control bar. But we have no idea how to repeat this issue with any of our sample applications dedicated to the dynamic control bars (such as SDI_DynamicBars or MDI_DynamicBars). In the most convenient case it should be possible to reproduce this issue with our sample applications if we know the exact sequence of user actions to reproduce it. Otherwise, you should try to find why it crashes in scope of your project. This can be done using several different attempts. First of all, please try to remember when the crash happens and what was changed in your project recently. If nothing comes to mind, you may want to comment out some parts of your project to find such the code combination when the app does not crash. In other words, this allows you to narrow the search..


Scott Moore Apr 4, 2009 - 3:27 AM

Thanks for the reply, I figured out the problem.  I was deleting my view when the dynamic bar was auto-hidden.  The fix was to check to see if the close button was pressed and not just check the visibility of the control bar with BarStateGet().