开发者

How do I localize ReportViewer labels, column headers, etc.?

I need to localize labels / column header for a ReportViewer report. From what I've read, there are two ways you can do this:

1) Create a RDLC file for each language or

2) Create one RDLC file and parse this at runtime, replacing the label/header values with the strings for the current culture.

I'm thinking #2 is gonna be less work in the long run, but I would like to confirm that the newest version doesn't support localization out of the box. Am I co开发者_JAVA百科rrect that I'll have to roll my own? Actually, I'll probably use the solution here.


I am not aware of localisation available in the 2010 (2008?) version but another quick option is included below:

An option I have used is to create a language dataset then pass in values from language files. So when you want to use a text string you end up with just references to dataset values, normally we used a long dataset with only 1 row and then used the first() function.

We stored XML files for languages and then just populated a dataset on the local report. Not too sure if that would work on remote mode reports though.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜