How to know when user types in Rich Edit Control?

I have a rich edit control in a dialog which may have some text already when dialog starts, I need to detect if user types inside this control, if user does, I want a hiding button  to show up. How to tell when user types something in control?

Thanks.
Hanqian
HanqianAsked:
Who is Participating?
 
AlexFMCommented:
To get this notification working add this line to OnInitDialog:

m_rich.SetEventMask(m_rich.GetEventMask() | ENM_CHANGE);   // m_rich is CRichEditCtrl class member
0
 
AlexFMCommented:
Handle EN_CHANGE message in the dialog - it is send by edit control to parent window when text is changed.
0
 
HanqianAuthor Commented:
I have tried EN_CHANGE before asking this question, it doesn't work.

Hanqian
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.