GetDlgItemText in an derived CComboBox
-
I try to make an CComboBoxExt derived from CCOmboBox . In
void CComboBoxExt::OnEditchange()
{
// TODO: Add your control notification handler code hereCString sText; GetDlgItemText(this?,sText); ShowDropDown();
}
I try to retrive the text that user entered in combobox , and if text is not empty show drop down list , if is empty then hide drop down list .. but I stuck on GetDlgItemText method : how can I retrieve the text that user entered ? Can you help me please ? Thank you !
-
I try to make an CComboBoxExt derived from CCOmboBox . In
void CComboBoxExt::OnEditchange()
{
// TODO: Add your control notification handler code hereCString sText; GetDlgItemText(this?,sText); ShowDropDown();
}
I try to retrive the text that user entered in combobox , and if text is not empty show drop down list , if is empty then hide drop down list .. but I stuck on GetDlgItemText method : how can I retrieve the text that user entered ? Can you help me please ? Thank you !
To retrieve text from the edit box of the CComboBox, use
GetWindowText()
. To retrieve text from the listbox, useGetLBText()
.Best wishes, Hans
-
To retrieve text from the edit box of the CComboBox, use
GetWindowText()
. To retrieve text from the listbox, useGetLBText()
.Best wishes, Hans
Thanks . Goes well.