how to programatically trigger CEdit EN_CHANGE?

  • Thread starter Thread starter IB00
  • Start date Start date
I

IB00

Guest
Manually entering text in an edit control triggers my EN_CHANGE event handler. This works well. For testing purpose, I would like to programmatically trigger the same CEdit EN_CHANGE event hander. Can someone tell me how this is done? I tried the following without success:



1) MyEditControl.SetWindowText( _T('test text") );



2) SendMessage( WM_COMMAND, (EN_CHANGE << 16) | IDC_EDIT), LPARAM(this->m_hWnd );



3) SendMessage( WM_COMMAND, (EN_CHANGE << 16) | MyEdit.GetDlgCtrlID()), LPARAM(this->m_hWnd );


Thanks


Ian



Continue reading...
 
Back
Top