Tech Support > Microsoft Windows > Development Resources > Repeat Count always shown 1
Repeat Count always shown 1
Posted by Admirer on November 11th, 2007


Im processing WM_CHAR and trying to print repeat count ,so that it
tells me the repeat count on continuous key press.But its always
one.Then whats the use of that repeat count field?

Posted by Scott Seligman on November 11th, 2007


Admirer <rrohithr@gmail.com> wrote:
The repeat count is only incremented if the system collapses several
WM_CHAR messages together because you don't process them fast enough.
Since these days you're generally going to process all the WM_CHAR
messages as they come in, the repeat count will just be one.

Think of the repeat count not as the number of times a character was
hit, but the number of times they key repeated since the last WM_CHAR
was processed.

--
--------- Scott Seligman <scott at <firstname> and michelle dot net> ---------
The man who reads nothing at all is better educated than the man who
reads nothing but newspapers.
-- Thomas Jefferson

Posted by Admirer on November 11th, 2007


Bu then how can I get the repeat count of a character using MSG's only

Posted by Scott Seligman on November 11th, 2007


Admirer <rrohithr@gmail.com> wrote:
You can't.

--
--------- Scott Seligman <scott at <firstname> and michelle dot net> ---------
Bodily exercise, when compulsory, does no harm to the body; but
knowledge which is acquired under compulsion obtains no hold on the
mind. -- The Republic by Plato

Posted by Christian ASTOR on November 11th, 2007


Admirer wrote:

e.g. with WM_KEYDOWN - WM_KEYUP


Similar Posts