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 » CExtPropertyGridComboBoxBar potential bug Collapse All
Subject Author Date
George Ross Nov 24, 2005 - 1:45 AM

Hi


If you try to remove all property stores from CExtPropertyGridComboBoxBar you get an assertin error. The problem,i think, is in CExtPropertyGridComboBoxBar::AssertValid() in


ASSERT( GetCount() == m_arrPropertyStores.GetSize() ); GetCount() calls also the AssertValid() that way enters an infinite loop.


PSE check it!!


 


regards


George


 

Technical Support Nov 24, 2005 - 5:48 AM

Please update the source code for the following method in the .../Prof-UIS/Src/ExtPropertyGridWnd.cpp file:

bool CExtPropertyGridComboBoxBar::PropertyStoreRemove(
    INT nPos // = -1 // if -1 - remove all
    )
{
    ASSERT_VALID( this );
    if( nPos < 0 )
    {
        m_arrPropertyStores.RemoveAll();
        if( GetSafeHwnd() != NULL )
            ResetContent();
        return true;
    }
    if( nPos >= PropertyStoreGetCount() )
    {
        ASSERT( FALSE );
        return false;
    }
    DeleteString( UINT(nPos) );
    m_arrPropertyStores.RemoveAt( nPos );
    return true;
}
The problem should not occur after that.