Home > Software engineering >  MFC c listbox control addstring problem solving
MFC c listbox control addstring problem solving

Time:09-19

M_listbox. AddString ();
In m_listbox error: undefined identifiers m_listbox

If change to int m_listbox. AddString ();
In. Place or error: an error should be input;

If changed to: int m_listbox;
M_listbox. AddString report or wrong
Error: should input type symbol

Problem description: in the listbox control points to add variables, m_listbox CListBox types of variables have been added to the

Some CStribg purpose: is to change the type of data to the listbox control and displayed in the listbox control,

CodePudding user response:

Int m_listbox;

CodePudding user response:

If the wizard to add two words

CListCtrl m_list;

DDX_Control (symbol, IDC_LIST1 m_list);

CodePudding user response:

Type should be CListBox
Bind variables when chose the int type?

CodePudding user response:

Variable declarations, wrong CListBox type variable, to the control and the variable binding to use

CodePudding user response:

Problem description: in the listbox control points to add variables, m_listbox CListBox types of variables have been added to the

The mouse position in m_listbox, press F12 or turn to the statement, confirm the type

CodePudding user response:

This question is too scary

CodePudding user response:

M_listbox is CListBox variable types, you add the control variables will be added automatically when the variable declaration, if you didn't add, but rather their statements,

CodePudding user response:

Int is the foundation type variable, not a class object, so call a class member method AddString error

The original poster is likely to be bullies on the hard bow

CodePudding user response:

Header files where statement

Int m_listbox;
To:
CListBox m_listbox;

Add variables of type choice is wrong, how a variable of type INT AddString () method,

CodePudding user response:

GetDlgItem (id) - & gt; Addstring ()
  • Related