Re:sending the output of a Timer control to a edit box control
Quote
On Sat, 06 Apr 2002 13:00:43 -0500, sd <sda...@yahoo.com> wrote:
>I'm writing a pedagogical program to compare binary vs. linear searches
>and I'm trying to use a timer control. Enabling and disabling the timer
>is no problem. The problem I am having is in sending the timer value to
>a edit box control. The code for the linear search is given below. )A
>search value is entered and an array (external to the search function is
>searched for the value. The search works fine. The problem is just in
>how I'm handling the timer). I have searched the available newsgroup
>posts for a similar problem and have found none at this time.
A TTimer doesn't have a "value" - its purpose is to trigger an event
after a preset interval. To /measure/ a time interval, call
GetTickCount(), which is a free-running millisecond counter i.e. call
it, store its result, run your code, call it again and subtract the
first value.