设置用户控件的文化和UI文化(.Net) [英] Setting the Culture and UI culture for a user control (.Net)

查看:97
本文介绍了设置用户控件的文化和UI文化(.Net)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,

我想以编程方式设置我的用户控件的区域性,它定义了几个标签,按钮和文本框等...

通常,对于aspx-pages,我们会覆盖 InitializeCulture -Method并设置Culture和UICulture来实现此目的,可惜ASCX-Controls没有此Method,那么我该怎么做呢?

我已经设置了本地资源mycontrol.ascx.de-DE.resx,mycontrol.ascx.resx和mycontrol.ascx.en-GB.resx,但是只有默认文件(mycontrol.ascx.resx)的值是用过的.

提前谢谢.
Santhosh

Hi everyone,

I''d like to programmatically set the culture of my User Control which defines several Labels, Buttons and Textboxes etc...

Usually, for aspx-pages we override the InitializeCulture-Method and set Culture and UICulture to achieve this, alas ASCX-Controls do not have this Method, so how exactly would I do this?

I''ve set up the local resources mycontrol.ascx.de-DE.resx, mycontrol.ascx.resx and mycontrol.ascx.en-GB.resx but only the values of the default file (mycontrol.ascx.resx) are used.

Thanks in advance.
Santhosh

推荐答案

看看

这篇关于设置用户控件的文化和UI文化(.Net)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆