This is a migrated thread and some comments may be shown as answers.

how to print multivalue parameter in textbox

2 Answers 207 Views
Report Designer (standalone)
This is a migrated thread and some comments may be shown as answers.
Lukasz
Top achievements
Rank 1
Lukasz asked on 12 Sep 2014, 09:50 AM
Hi,

I have multvalue parameter with available values connected to ObjectDataSource:

IEnumerable<int> GetMonths()

Now I am trying to display first value from that list in TextBox:

{=First(Parameters.Months.Value)}

This renders as empty.

But this works:

{ = Join(",",Parameters.Months.Value)}

How can I use agregate fuctions on multivalue parameters?

Thanks,
Ɓukasz

2 Answers, 1 is accepted

Sort by
0
KS
Top achievements
Rank 1
answered on 17 Sep 2014, 12:35 PM
Hi,

As far as I know the Parameters.Param.Value of multivalued parameter is a System.Object[], and is not operating as a standard field. Probably a user function can get the needed value, just pass the Parameters.Param.Value or Parameters.Param.AvailableValues and cast it.

-KS
0
Lukasz
Top achievements
Rank 1
answered on 17 Sep 2014, 12:40 PM
Yes, thanks.

I finally ended using user functions to extract everything what I need from multivalue parameters.
Tags
Report Designer (standalone)
Asked by
Lukasz
Top achievements
Rank 1
Answers by
KS
Top achievements
Rank 1
Lukasz
Top achievements
Rank 1
Share this question
or