Jump to content
Tuts 4 You

ComboBox event when selected item text was changed and finalized


CodeExplorer

Recommended Posts

Posted (edited)

Hi. I looking for something...
ComboBox event when selected item text was changed and finalized??? - After selected value changed!
Visual C++ 6.0

 

Edited by CodeExplorer
  • The title was changed to ComboBox event when selected item text was changed and finalized
Posted

@fearless: Thanks.
I solved this this using OnSelchangeCombo1 and getting index (has proper value) - only text was not updated,
like this:

void DefineImport::OnSelchangeCombo1()
{
    // TODO: Add your control notification handler code here
    CWnd* hcombo = GetDlgItem(IDC_COMBO1);
    int index = ::SendMessage(hcombo->m_hWnd, CB_GETCURSEL, 0, 0);

    char ptext[512];
    SendDlgItemMessage(IDC_COMBO1, CB_GETLBTEXT, index, (LPARAM)(LPCTSTR)ptext);

 

  • Like 1

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...