Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How To get the view parameter in the view result
Message
From
14/04/2015 09:27:03
 
 
To
14/04/2015 09:16:09
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Windows 8
Network:
Windows 2008 Server
Database:
Visual FoxPro
Application:
Desktop
Miscellaneous
Thread ID:
01618350
Message ID:
01618376
Views:
31
>Hello Gregory,
>
>Thank you for answering.
>
>I am afraid CA are not an option here.
>
>My situation is like so:
>
>In an existing App of ours the customers are allowed to create reports of their own. They also create the views, the reports are based on. In a special case now a customer likes to have data selected depending on WHERE YEAR( DATEFIELD ) >= ?lnYear. The year entered should be listed in the header of the report.
>
>That is the reason for my question.
>
>As Lutz already said, there seems to be no way to get the value of the view parameter in the header of the report, right?
>

You could include the parameter in the view ( in this case)
select Table.*, ;
         cast ( ?lnYear as Int ) as MyParam;
        from ....
       where (YEAR( DATEFIELD ) >= ?lnYear )
What I do is to create another cursor (HeaderCursor) and add one record with the fields I need

I have many fields in there ( YearStart, YearEnd, .... even images )

Then in the report when I want print that data, Field expression = HeaderCursor.NameOfField

>Gerhard
Gregory
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform