Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Toolkit Pro
  New Posts New Posts RSS Feed - Combo Box With Icons
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Combo Box With Icons

 Post Reply Post Reply
Author
Message
Maneesh View Drop Down
Newbie
Newbie


Joined: 02 May 2005
Status: Offline
Points: 16
Post Options Post Options   Thanks (0) Thanks(0)   Quote Maneesh Quote  Post ReplyReply Direct Link To This Post Topic: Combo Box With Icons
    Posted: 02 May 2005 at 7:51am

Hello

How can i create a combobox as a toolbar item and have items with an ICON and its Name like

<Excel Icon> Microsoft Excel

<OPen Icon> Open File

as Drop Down items.

Using xtreme toolkit pro !

Back to Top
Oleg View Drop Down
Admin Group
Admin Group


Joined: 21 May 2003
Location: United States
Status: Offline
Points: 11234
Post Options Post Options   Thanks (0) Thanks(0)   Quote Oleg Quote  Post ReplyReply Direct Link To This Post Posted: 06 May 2005 at 1:06am
Sorry, but we plan to implement Icons from ComboBox only for 10.0 release.
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
Maneesh View Drop Down
Newbie
Newbie


Joined: 02 May 2005
Status: Offline
Points: 16
Post Options Post Options   Thanks (0) Thanks(0)   Quote Maneesh Quote  Post ReplyReply Direct Link To This Post Posted: 14 May 2005 at 3:52am

Well oleg Iam sorry .... I was able to do it !!! with Xtreme Toolkit pro !

I am not sure whether u understood the problem ~~

well hers the code !

Assume the toolbar button id is IDM_COMBO_SOURCE__BTN and in the OnCreateControl check for this !!!

CXTComboBoxEx m_SourceCombo;

 if (  pToolBar && pToolBar->GetBarID() == IDR_STANDARD_TOOLBAR )
 {
  //-- CREATING THE SOURCE COMBO BOX ITEM
  if ( lpCreateControl->nID == IDM_COMBO_SOURCE__BTN )
  {
   m_SourceCombo.Create( CBS_DROPDOWNLIST|WS_TABSTOP | WS_CHILD | WS_VISIBLE  , CRect( 0 ,0 , 200, 100) , this , ID_SOURCE_COMBOBOXITEM );
   
   CXTPControlCustom* pControlComboBox = CXTPControlCustom::CreateControlCustom(&m_SourceCombo);
   lpCreateControl->pControl = pControlComboBox;

}

 

Then use the InsertItem() fn to of teh combo box classs  to add the items in the combo and u can also set icons or bitmaps to each item !!!

 

Thanks

Maneesh

Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.078 seconds.