Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
SCAN WHILE- scope doesn't default to ALL
Message
De
20/03/2006 21:27:23
John Ryan
Captain-Cooker Appreciation Society
Taumata Whakatangi ..., Nouvelle Zélande
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Titre:
SCAN WHILE- scope doesn't default to ALL
Versions des environnements
Visual FoxPro:
VFP 9 SP1
Divers
Thread ID:
01106077
Message ID:
01106077
Vues:
70
I just found an irritating bug in some code that uses a SCAN WHILE...ENDSCAN loop.

The loop was not catching some of the records. I subsequently found that SCAN is starting at record 11, which is RECNO() when the SCAN executes. It seems that the scope is defaulting to REST rather than ALL. According to online Help and in all my previous use of SCAN, scope defaults to ALL. Explicitly specifying ALL fixes the problem.

So, I'm wondering whether this is a known feature or a bug? Either way, a modification to the Help file would be helpful.
"... They ne'er cared for us
yet: suffer us to famish, and their store-houses
crammed with grain; make edicts for usury, to
support usurers; repeal daily any wholesome act
established against the rich, and provide more
piercing statutes daily, to chain up and restrain
the poor. If the wars eat us not up, they will; and
there's all the love they bear us.
"
-- Shakespeare: Coriolanus, Act 1, scene 1
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform