Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Class calling a report - passing variables
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00104020
Message ID:
00104153
Vues:
23
>I'm trying to pass variables from one of my classes to a report. Do I need to make the variable public to pass it to the report? Will the variables be automatically released when the object is destroyed? In my current program, I've got a form (actually, it's a class/object based on a form). I also have another class I call from this form that does all of the work for the report. So in my print button on the form I do something like:
>
>lnReportType = THISFORM.Combo.Value
>lcLocation = THISFORM.Combo2.Value
>THISFORM.ReportObj.Print(lnReportType,lcLocation)
>
>In the ReportObj, Print Method I generate the cursor then run the report. I need to pass the lcLocation variable to the report so I can display this in the title(and, I guess pass the cursor). Help and suggestions appreciated. Now I understand why everyone wishes the reports were OO.
Paul,

No your variables need not be public they only need to be private which is the default scope for variables.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform