Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Can I use substitution field names in reports?
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire de rapports & Rapports
Divers
Thread ID:
00175257
Message ID:
00175262
Vues:
27
>Here's my example:
>
>I select the data I want included in the report to follow.
>
>SELECT mytable.&cField FROM mytable ;
> WHERE .... ;
> ORDER BY mytable.&cField ;
> INTO CURSOR rpt
>
>SELECT rpt
>
>I run the report.
>
>REPORT FORM MYREPORT.FRX TO PRINT
>
>In the report designer I want to use rpt.&cField as one of the fieldnames in the report, but it calls it a syntax error. Any work around for this one?
>
>I predesigned the report form using the report designer and supplied fieldnames at that time.

You'd be much better off having your SELECT statement use AS clauses to assign names to the desired fields. In general, the more you avoid macro expansion, the less trouble you're going to encounter. In this case, using macro expansion in the report buys you absolutely nothing.
EMail: EdR@edrauh.com
"See, the sun is going down..."
"No, the horizon is moving up!"
- Firesign Theater


NT and Win2K FAQ .. cWashington WSH/ADSI/WMI site
MS WSH site ........... WSH FAQ Site
Wrox Press .............. Win32 Scripting Journal
eSolutions Services, LLC

The Surgeon General has determined that prolonged exposure to the Windows Script Host may be addictive to laboratory mice and codemonkeys
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform