Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Accessing A Form's Value As A Report Variable
Message
From
30/03/2002 13:43:33
Carmen Gassi
Perseus Software Systems
Oakville, Ontario, Canada
 
 
To
30/03/2002 13:19:11
General information
Forum:
Visual FoxPro
Category:
Reports & Report designer
Miscellaneous
Thread ID:
00639158
Message ID:
00639168
Views:
20
Hi Greg
Your first suggestion worked nicely, although I had to declare the variable to store the name of the month as public. When I tried it as private, the report did not know of it. I thank you for your suggestion.

Regards,
Carmen
>>Hello All
>> I am producing a report, that takes as one of its values, the contents of a form's property. On the form in question, the user selects a month for the particular report. A simple DoCase..Endcase assigns the name of the month for the particular spinner value. The report is then launched via a command button on the form. I have set up a field control on the report that uses the property from the form as follows:
>> formname.property . Now when I am modifying the form and I run it, the report picks up the value of the property perfectly and displays the control on the form. When I build the application and run it, it treats the form's name as an alias and the form errors out. Am I missing a setting on the report end, or is the syntax for accessing a property from an active form incorroect? Thanks for suggestions.
>>
>>Regards,
>>Carmen
>
>Carmen,
>
>You are never sure about the formname since a form may be active more than once at the same time. Also, I do not think that formnames are available in the runtime. They just serve for debugging purposes.
>
>There are as far is I know two possibilities for handling this
>
>(1)
>in the form
>private Var1
>Var1 = thisform.Property
>
>report form... && reference Var1 in the report
>
>(2)
>in the form
>private oForm
>oForm = thisform
>report form ..... && reference oForm.Property
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform