Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Stopping a Long Routine
Message
From
10/10/2005 14:01:21
 
 
To
10/10/2005 13:56:14
Mike Smith
Doncaster Office Services
Oakville, Ontario, Canada
General information
Forum:
Visual FoxPro
Category:
Other
Environment versions
Visual FoxPro:
VFP 8
Miscellaneous
Thread ID:
01057205
Message ID:
01057725
Views:
8
>Fred:
>
>You are right! It stops properly now.
>
>Thank you for your advice.
>
>
>Mike Smith

Glad it helped, Mike.

If you find that your loop has been slowed down considerably, you might want to execute the DOEVENTS only after several iterations of your loop have ocurred.
nCounter = 0
FOR x=1 TO 1000
  nCounter = nCounter + 1
  IF MOD(nCounter,50)=0
    DOEVENTS
  ENDIF
  IF YourStopCondition
    EXIT
  ENDIF
  ...
ENDFOR
Fred
Microsoft Visual FoxPro MVP

foxcentral.net
Previous
Reply
Map
View

Click here to load this message in the networking platform