We have migrated from Asp.Net Report viewer to HTML5 Report viewer recently and facing trouble towards “Localizing HTML5 Report Viewer”.
Online documentation talks about .trdx report localization using JavaScript file like resources.[culture].js.
However we are looking for localizing Asp.Net web Forms reports (i.e. cs Reports files) with HTML5 report viewer.
Attached are the screenshots of
1. localize Asp.Net Web Form Report (Using .RESX files) -- refer TelerikReportViwer.png
2. HTML5 Report viewer with same report file used in 1 above - refer html5ReportviwerReport.png
Can you pls advise how best we can continue further with our localization of HTML5 Reports ?
regards,
Chetan
9 Answers, 1 is accepted
If you need to localize your reports, we use the mechanism described in the Localizing Reports article. In addition, you can subscribe for the report's Error event and provide custom handling for errors occurring on report processing.
To localize the HTML5 Report Viewer resources, check the HTML5 Report Viewer Localization help article. The text resources can be found in the viewer's telerikReportViewerTemplate.html file, which can be customized per your needs.
The culture of the thread has to be set before the view with the viewer is displayed or the report processing begins. Based on the following blog post: Localization in ASP.NET MVC 4, you can change the culture settings on on request.
Regards,
Stef
Telerik
Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.
Thank you for your reply. We did go through these articles before but couldn't relate as per our current scenario.
Here is the case -
1. We have Asp.Net Web application (Not MVC App) with Asp Web Forms Report Viewer in place calling telerik reporting (.cs files). This setup was using .resx files for localizing reports. It worked well (refer earlier attached TelerikReportViewer.png)
2. Now we were migrating towards utilising HTML5 report viewer. We only replaced Asp Web Report Viewer with HTML5 report viewer,keeping Web Project, Telerik reporting cs files as it is. ( so technically only HTML5 Report viewer is being used with Asp.Net Web app).
3. Here the challenge is to localize this html5 report viewer with existing setup of .resx files (which we believed now wont work with hrml5 report). refer earlier attached html5ReportViewerReport.png
So can you pls advise how we can localize this html5 report viewer using this scenario.
Thanks,
Chetan
The HTML5 Report Viewer uses different localization mechanism. The viewer is a client-side widget consisting of standard HTML elements and Telerik Kendo UI widgets with specific styles. Thus the old resx files cannot be used in the case.
Regards,
Stef
Telerik
Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.
Hi Chetan,
i am also working on localization of telerik reporting.please can you share the sample code of implementation of localizing telerik reports by calling telerik_reporting (.cs files) using .resx files in your main web application.
thanks in advance.
Please double-check if the culture is set correctly at the time the viewer makes a request for report - Localization in ASP.NET MVC 4. If the culture is set correctly, reports will used the localization strings saved in the resx file with the corresponding culture.
About the HTML5 viewer, it uses different localization strategy not based on resx files - HTML5 Report Viewer Localization.
Regards,
Stef
Telerik
Hi Stef,
Thank you for your reply. We did go through this"Localization in ASP.NET MVC 4 "article,and we rechecked what mistake we done previously,we follow all the steps but we missed settings in route.config file. now the issue is resolved.
regards,
Krishna.
You can review Product Catalog Demo located in Telerik Reporting installation folder: <installation folder>/Progress/Telerik Reporting <version>/Report Designer/Examples/Product Catalog.trdp. It demonstrates how you can bind report's culture to a parameter passed by end-user so the culture can be changed dynamically.
The approach for localizing report is provided in Localizing Reports help article.
Regards,
Katia
Progress Telerik