CompuServe Thread

Combo Box on ToolBar

1 messages in this thread
#30472From: Rick MastersJul 11, 1994 3:49 AM
I'm having a problem with a CComboBox on a CToolbar in a COleInPlaceFrame. (I get an assertion when the frame is destroyed ONLY if i've previously clicked on the combo box!) To reproduce, add the following code to scribble, step 7, IPFRAME.CPP, to the end of OnCreateControlBars(): CRect rect; rect.top = 1; rect.bottom = rect.top + 100; rect.left = 200; rect.right= 300; if (!m_comboBoxSym.Create(CBS_DROPDOWNLIST|WS_VISIBLE|WS_TABSTOP, rect, &m_wndToolBar, IDW_COMBO_SYM)) { TRACE("Failed to create combo-box\n"); return FALSE; } (make m_comboBoxSym a CComboBox and a member of CInPlaceFrame. #define IDW_COMBO_SYM to 110) To cause the assertion: 1. Now, insert a SCRIB file into Word 6.0 2. Click on the new Combo box. 3. Click outside the object to deactivate it. The assertion is wincore.cpp, line 210. I don't understand the code at this location. Please help if you know how to create a control on a toolbar that is used by a OleInPlaceFrame. Thanks!