Hi there
Can somebody please tel me how i can capture the Preview button click event. This will help me to solve lots of issues i am facing in my report development.
1. A report parameter that value should be sent to the business layer and to repopulate the report datasource based on that.
2. Is there anyway to turn off caching of report so that it always look for the code to bind datasource.
4 Answers, 1 is accepted
0
Hi Sekar,
Currently the report parameter's area is a separate iframe and you cannot capture the preview button click. However, you should not need to capture it in a first place. You can set the report's datasource in the NeedDataSource event handler and there access the report parameters of the processing report as needed.
Note the NeedDataSource event is fired only when there is no DataSource set to the report i.e. you have this.DataSource = null in the report constructor.
Sincerely yours,
Steve
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
Currently the report parameter's area is a separate iframe and you cannot capture the preview button click. However, you should not need to capture it in a first place. You can set the report's datasource in the NeedDataSource event handler and there access the report parameters of the processing report as needed.
Note the NeedDataSource event is fired only when there is no DataSource set to the report i.e. you have this.DataSource = null in the report constructor.
Sincerely yours,
Steve
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
0
Stuart
Top achievements
Rank 1
answered on 16 Mar 2011, 05:35 AM
Strictly speaking you can using JQuery:
$("#ReportViewer1ParametersArea").load(function() {
$("#Preview", $("#ReportViewer1ParametersArea").contents()).click(function() {
alert("I've been clicked!");
});
});
0
Moumit
Top achievements
Rank 1
answered on 18 Apr 2012, 07:42 AM
i have a situation in reporting where i need to validate according to business logic. so i need preview button click event. How to do that???
I explaining situations where i need it....
I have Three parameter in this report.
SubledgerID -Combobox
DateFrom- Datetimepicker
DateTo-Datetimepicker
i need to validate that 'DateFrom <= DateTo' whenclicking in preview button ...........
what is the solutions...????
I explaining situations where i need it....
I have Three parameter in this report.
SubledgerID -Combobox
DateFrom- Datetimepicker
DateTo-Datetimepicker
i need to validate that 'DateFrom <= DateTo' whenclicking in preview button ...........
what is the solutions...????
0
Hi,
Steve
the Telerik team
The built-in report parameters' purpose is to provide basic UI that is available out of the box and that is enough for most scenarios. For other cases, when you require customization or in your case validation you can hide all report parameters (Visible=false), create a custom parameter area and wire it up to the Report API.
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 >