Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

onChar issue

Status
Not open for further replies.

BeeerFizz

Programmer
Dec 14, 2005
5
US
Hi,

within a dialog, which has several edit boxes and buttons, I have defined a message handler for WM_CHAR using the class wizard. This creates

void CKeyFromSource::OnChar(UINT nChar, UINT nRepCnt, UINT nFlags)
{
int i;
i = 1; // break here
CDialog::OnChar(nChar, nRepCnt, nFlags);
}

I have a break on the i=1 line;

This break is never hit...

Do I have to do something to cause these messages to be passed along?
Is there something which inhibits these messages?
I am using Visual C++ 6.0

Thanks for all help.
 
In order to use the WM_CHAR message you will have to create a class, connect it to the edit box, then create the subclass message handler.

There is an example in "Practical Visual C++ 6"
by Jon Bates and Tim tompkins
a QUE book.


HyperEngineer
If it ain't broke, it probably needs improvement.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top