Report Design
 Crystal Reports Forum : Crystal Reports 9 through 2020 : Report Design
Message Icon Topic: Passing multiple or range param problem Post Reply Post New Topic
Author Message
wanamingo
Newbie
Newbie
Avatar

Joined: 18 Sep 2012
Online Status: Offline
Posts: 5
Quote wanamingo Replybullet Topic: Passing multiple or range param problem
    Posted: 03 Oct 2012 at 7:21am
So ive created a report that prints out some serial numbers based on a work order. Its simplifying one of the processes where I work.

 The report does what it is supposed to do but there has been a request to enter some serial numbers manually, in case they need duplicates or in some cases serial numbers aren't attached to a work order.

I cant seem to be able to pass either a range or multiple value parameter based on manual entry, the entries are just blank. Ive posted a similar problem here before and was told it had to do with no database being attached to the manual entry field.

Anyone have any suggestions?
IP IP Logged
Sastry
Moderator
Moderator
Avatar

Joined: 16 Jul 2012
Online Status: Offline
Posts: 537
Quote Sastry Replybullet Posted: 03 Oct 2012 at 7:01pm
Hi
 
If we pass multipul values through parameter then it creates an array and if you place the paramter in your report it will show the first value only. To display all values try to with the following :
 
Join({?parameter},',')
 
It will join all your values by separating with comma.  If you want to place the first value of your parameter then you need to use split() function.
 
Ex :
 
split(join({?parameter{,','),',')[1]
 
Play around with this functions
Thanks,
Sastry
IP IP Logged
wanamingo
Newbie
Newbie
Avatar

Joined: 18 Sep 2012
Online Status: Offline
Posts: 5
Quote wanamingo Replybullet Posted: 04 Oct 2012 at 8:17am
Thanks for the response! Ive tried playing around with the Join function but unfortunately when applied to my parameter crystal says "A string Array is Required here" and points to my parameter. I know its a string value, and a range / multiple value parameter.

Any other suggestions?
 
IP IP Logged
Sastry
Moderator
Moderator
Avatar

Joined: 16 Jul 2012
Online Status: Offline
Posts: 537
Quote Sastry Replybullet Posted: 04 Oct 2012 at 7:01pm
HI
 
If you don't give any value or if you give only one value to your parameter then it will give you such kind of errors.
 
Try the following :
 
If count({?Parameter}) > 1 then
Join()
else
{?Parameter}
Thanks,
Sastry
IP IP Logged
wanamingo
Newbie
Newbie
Avatar

Joined: 18 Sep 2012
Online Status: Offline
Posts: 5
Quote wanamingo Replybullet Posted: 11 Oct 2012 at 8:27am
Thanks again for the reply unfortunately I am still having issues. I never expected to get stuck with this part of the report.

Playing around with the formula you gave me I am getting an error of "The field cannot be summarized" of the first instance of the parameter.

I dont see why crystal would make it so difficult to enter in simple numeric ranges not based on a field.

Thank you again for the timely reply. Any other suggestions?


IP IP Logged
Post Reply Post New Topic
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum



This page was generated in 0.031 seconds.