views:

50

answers:

1

I cannot figure out why HeaderText or validation controls always fallback to default culture - even though rest of the controls are in correct culture.

I have a GridView with HeaderText specified in this way>

<asp:BoundField DataField="totalSales" HeaderText="<%$ Resources:Strings,TotalSales %>" />

In the same way I have validation controls and they can't be localized.

Only this syntax does work: <%= Resources.Strings.Payments %>

I set different culture in Master page using this statement in Page_Init

Me.Page.Culture = "pl-PL"
Me.Page.UICulture = "pl-PL"

Can anyone spot what's wrong? I have been Googling it for last few days without success.

Thanks!

+1  A: 

Have you tried to use ExpressionBuilder? That works very well and allows you to localize everything using the same approach.

Sander Pham