1应该在构造函数中设置m_strEdit的值,或者在OnInitDialog末尾手动调用UpdateDate(FALSE).CDialog::OnInitDialog也会调用这个函数来初始化控件成员。 2EN_CHANGE The EN_CHANGE notification message is sent when the user has taken an action that may have altered text in an edit control. 也就是说,只有用户操作才会通知,程序的操作是不会发送通知消息的。不过你可以自己手动通知。
2EN_CHANGE
The EN_CHANGE notification message is sent when the user has taken an action that may have altered text in an edit control.
也就是说,只有用户操作才会通知,程序的操作是不会发送通知消息的。不过你可以自己手动通知。
还有一种方法你可以把你的 m_strEdit(改成Control).也就是CEdit类.
这样你就可以直接用m_strEdit.SetWindowText(_T("Initialize"));来更新.