Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Data type mismatch when selecting a cursor
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 7 SP1
OS:
Windows XP SP2
Database:
Visual FoxPro
Divers
Thread ID:
01181952
Message ID:
01182193
Vues:
13
Thanks to both of you for your help. I made change to my code as you suggested. The declaration of the variable within a loop was really "weak" from my part. The DO WHILE loop is an inheritance from FoxBase +. I didn't know that the SCAN command remain attach to the initial table without need to reselect the table in the loop.

The code is now "cleaner" but the bug remained the same but, surprise, it append now on the last ENDSCAN line in the first loop.

When I ran the application in the debugger executing the code line by line (F8) I had no error but if I press F5 from my toggle point the bug appear.

SELECT rv
SET ORDER TO noclient
SELECT curProspect
SET ORDER TO 0
GO TOP

LOCAL nContrat
SCAN
cTel = telres
nContrat = nocontrat
SELECT rv
SEEK cTel
SCAN WHILE NoClient = cTel for nocontrat = nContrat AND !print
REPLACE rv.print WITH .t.
ENDSCAN
ENDSCAN

************** Solution that I found *************

Finally, I decided to release a relation concerning the RV ( parent ) table before to proceed to the loop and restore it after and surprise! The bug desappear!?!?!?

Did you heard about of a problem with datas alignment within relation in VFP?

Have a nice day and thanks again
Have a nice day,

Normand
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform