Home > Software engineering >  MFC combox controls,
MFC combox controls,

Time:11-20

The drop-down list if there is A, B, C, three options, when choosing A MessageBox pop-up A. Similarly, choose B, pop-up b.

In response to an event I join if judgment, if get the index value is 0 (A), should be A pop-up a. but I choose B, he also pop up A.
Ask bosses to help explain, why do I always play out A. Thank you!

CodePudding user response:

This depends on how the code you write,
May be you should add
at the beginning of the functionThe UpdateData ();

CodePudding user response:

Response of ON_CBN_SELCHANGE int iSel=m_CbCtrl. GetCurSel ()

CodePudding user response:

A counting from zero, there is a counting from 1

CodePudding user response:

Positive solution to second floor

CodePudding user response:

2 floor!!!!!!