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

MVC ReportViewer set culture

1 Answer 63 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
El Barto
Top achievements
Rank 1
El Barto asked on 16 May 2017, 07:13 PM
I've got a seemingly simple question. I've designed a multilanguage report. The report is going te be used on a MVC webpage. How do I pass the selected culture of the user to the report so it will be rendered in the correct language? I can set the thread culture in the report init code and it works. I can set a culture in the controller/view which has the reportviewer but this has no efffect as the report is rendered in another thread. 

1 Answer, 1 is accepted

Sort by
0
Stef
Telerik team
answered on 19 May 2017, 02:05 PM
Hello,

Please check the details and the example in this forum thread (based on Localization in ASP.NET MVC 4 by Michael Chambaud).

The HTML5 Viewer and Reporting REST Service work in a client-server mode, where the MVC application appears as a client to the service which defines its own server context. To transfer the culture from the client to the server, you can use the event firing on sending a request to the server (the viewer uses AJAX requests to post information to the server).

Regards,
Stef
Telerik by Progress
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Tags
General Discussions
Asked by
El Barto
Top achievements
Rank 1
Answers by
Stef
Telerik team
Share this question
or