[comp.windows.ms] using windows serial I/O

bturner@hpcvlx.HP.COM (Bill Turner) (01/12/89)

>  Also on a different subject, is it possible to enter text into Edit type 
>  window not from a keyboard, i.e.  receive a character from the serial port
>  and enter it into the window of the Edit class, and is it possible, 
>  with the Edit type window, to track keyboard characters, so that they can
>  be filtered out before going to the Edit class window.

I can't answer your first question on using ReadComm, but I can help on the
edit field questions.

First, you can send text to the Edit field by using SendMesssage(WM_CHAR).
Nice how that works (and surprising, too, knowing some of what Microsoft
has done...).

You can subclass the edit field to filter input messages -- basically, you
substitute your own window proc that handles some messages and passes the
rest to the regular edit field processing.  I have a sample program that
does this (creating a numeric-only edit field); e-mail me for a copy, or if
there is demand I can post it.

--Bill Turner (bturner@hp-pcd)
HP Corvallis Workstation Operation