Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
IF statements going to first record in table
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Titre:
IF statements going to first record in table
Divers
Thread ID:
00155216
Message ID:
00155216
Vues:
76
Hi all,

We have a function button which does the following command in our app:

do printrec

We have been trying to implement a procedure using IF statements which will print a certain report based on field criteria. For example, IF field="x", print a certain report. This works for one IF statement at a time. We have a function button which does this - when the user is on the record, you just press this button and it prints the record with the report.

However, the user has been trying to do this with a lot of IF statements strung together, like so:

IF field='X'
do printrec with "F", "PA"
endif

IF field='Y'
do printrec with "F", "PB"
endif

etc.

What happens is that it will print the selected report for the current record, but then it will to print the report for the first record in the table, then do it again. We only want it to print the report for the current record.

Are there some other commands I need to insert in the procedure which will stop it from going back to the first record?

Thanks for any and all help!

Dave D'Amico
ddamico@fmsystems.com
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform