xHarbour Reference Documentation > Function Reference xHarbour Developers Network  

WaitPeriod()

Defines a wait period and allows for time controlled loops.

Syntax

WaitPeriod( [<nTime>] ) --> lPeriodIsActive

Arguments

<nTime>
If specified, this is a numeric value indicating the wait period to install. The unit is 1/100th of a second.

Return

The function returns .T. (true) while the period of <nTime> * 100 seconds has not elapsed since the initial call. After the wait period is over, the return value is .F. (false).

Description

An initial call to WaitPeriad() defines a time span in 1/100 seconds. The function returns .T. (true) in subsequent calls until the wait period has elapsed. This allows for programming time controlled loops in this form:

   WaitPeriod(100)

   DO WHILE WaitPeriod()
      <do something>
   ENDDO

Info

See also:MilliSec(), Seconds()
Category: CT:DateTime , Date and time
Source:ct\settime.c
LIB:xhb.lib
DLL:xhbdll.dll


Copyright © 2006-2007 xHarbour.com Inc. All rights reserved.
http://www.xHarbour.com
Created by docmaker.exe