Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Toolkit Pro
  New Posts New Posts RSS Feed - CXTPControlComboBox notification message problems
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

CXTPControlComboBox notification message problems

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


Joined: 11 May 2007
Status: Offline
Points: 14
Post Options Post Options   Thanks (0) Thanks(0)   Quote Joe19 Quote  Post ReplyReply Direct Link To This Post Topic: CXTPControlComboBox notification message problems
    Posted: 27 May 2007 at 12:44am

I have a CXTPControlComboBox control used in a RibbonBar.  The only notification that I can get if the user edits the edit control of the combobox is a CBN_EDITCHANGE message.  ON_XTP_EXECUTE does not fire on the edit change (only the listbox change).  The problem is that when the user uses the listbox part of the control, there are actually two CBN_EDITCHANGE messages fired.  I traced this to the function _SetEditText.  When this function is called to insert text into the edit control, if first inserts a NULL entry (causing the message to fire) and then inserts the "real" text causing the second message.

My work around is to test if the GetEditText returns an empty string (the NULL insert) and then ignore that message.  However this forces me to not allow the user to have an empty string as a valid input.

 

Back to Top
Oleg View Drop Down
Senior Member
Senior Member


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: 28 May 2007 at 6:56am
Thanks, we will add flag to ignore first CBN_EDITCHANGE.
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
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.047 seconds.