Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Shared Variables and User Parameters

Status
Not open for further replies.

garlix

MIS
Dec 16, 2004
5
0
0
DE
I think I am correct in saying that user-inputted parameters cannot be applied to formular fields containing shared variables as these fields are calculated "whileprinting" records..?

But is there any work-around for this?

I have a pretty simple report with one grouping and no sub-reports. The particular field I need to apply a user-inputted parameter to contains a shared variable and is displayed in the group footer. (The report details section is blended out.)

Is there anyway I can get CR (version XI R2) to allow the user parameter on this field?

Many thanks.
 
You can use parameters--not in the select expert, but you could use them in a shared variable formula. Depends upon what you are trying to do.

-LB
 
Thanks for the quick reply.

Yes, it's in the select expert where I need to use the parameter, as a user input filter, which is as you say, not possible.. :-(

I think I can achieve what I need by using the parameter in the section expert to suppress the results that are not required, but this is not a very efficient filtering method.

Is there maybe another way to achieve this that anyone knows of?
 
What is the content of the formula you want to filter on?

-LB
 
Basically my report pulls, among other things, transport status information.

In the formula under discussion here, the freight forwarder branch entering particular status codes is pulled. The formula, which is positioned in the report details section, looks like this:

if {shipstatus.status} in ["ISC","SCD"]
then shared stringVar branch := {shipstatus.branch};

In the group footer the following formula simply displays the branch, that is, if one is found:

shared stringVar branch;

The user of the report has now requested the possibility to filter for particular branches. The problem is as stated that the relevant branches are not actually known until the report has finished reading the records.

Hope I have explained the situation clearly enough.
 
Try filtering by status codes and branches in the selection formula like this:

{shipstatus.status} in ["ISC","SCD"] and
{shipstatus.branch} = {?Branch}

-LB
 
Yes I think that will work.

Many thanks for your help.
 
I have a similar situation (in Crystal XI) only I'm trying to enable the user to select either all records or records with a positive value. Below is the formula:
Code:
Sum ({'Schedules_Excel_Download_'.Open Sched Qty}, {'Schedules_Excel_Download_'.Part Nbr})-({@InProdQtyPassed}+{@OnHandQtyPassed})

I tried creating a variable for this formula and followed the example but I don't have a corresponding field for the summary result.

I'm going to keep trying different solutions but any help would be greatly appreciated!!

Thanks!
 
Please start a new thread. I don't see how your topic is at all related to the current thread. In your new post, show the content of all nested formulas, too.

-LB
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top