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

using ReportParameters

1 Answer 107 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
c
Top achievements
Rank 1
c asked on 17 May 2012, 09:22 AM

Hi There,

There are 2 problems about the Report Parameters.

1,I have a textbox in the pageHeaderSection and i want to set its value at runtime.Now i have add a parameter named 'Title',but i can't find any event of the report like 'loaded',there is only disposed event .So how i pass the parameter value to the textbox at runtime?

2.As we know,the SqlDataSource component supports parameterized SQL query and i'm using Oracle provider.Now i write a sql as

'SELECT * FROM Person WHERE Name in :Name' .The parameter 'Name' is a array,and my code is like ' new Parameter() {Key = "Name",Value = "('A','B','C')"}',But it doesnt work.How should I edit the 'Value' set to the parameter 'Name'?

Thanks

1 Answer, 1 is accepted

Sort by
0
Steve
Telerik team
answered on 21 May 2012, 09:42 AM
Hi,

Thanks for your interest in Telerik Reporting and up to your questions:
  1. You can have the report parameter value directly as expression in the TextBox in page header, see Using Report Parameters in Expressions help article for more info.
  2. As explained in Using Multivalue Parameters article, the report engine rewrites queries for data sources that cannot process parameters as an array. The rewrite logic is triggered when a parameter is defined as multivalue and the database query uses an IN statement to specify the parameter.

All the best,
Steve
the Telerik team

BLOGGERS WANTED! Write a review about Telerik Reporting or the new Report Designer, post it on your blog and get a complimentary license for Telerik Reporting. We’ll even promote your blog and help bring you a few fresh readers. Yes, it’s that simple. And it’s free. Get started today >

Tags
General Discussions
Asked by
c
Top achievements
Rank 1
Answers by
Steve
Telerik team
Share this question
or