Flex NumberFormatter 根据 Windows

发布于 2024-07-16 10:08:23 字数 138 浏览 4 评论 0原文

是否可以直接根据windows设置NumberFormatter的属性
“区域设置”?

如果没有的话,Flex中有一个函数我们可以通过它得到 区域设置,然后我们可以更改NumberFormatter的属性 根据它。

Is it possible to directly set the properties of NumberFormatter according to windows
" Regional Setting "?

If not, it there a function in Flex by which we can get
the Regional Setting, and then we can change the properties of NumberFormatter
according to it.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

浮云落日 2024-07-23 10:08:23

以下是有关 Flex 中本地化工作原理的一个很好的教程:

http ://livedocs.adobe.com/flex/3/html/help.html?content=l10n_1.html

至于检测用户的区域和/或语言,您可以在 ActionScript 中尝试:

Capabilities.language

或者类似Javascript 中的 this(通过 Flash 的外部接口调用):

var lan = ((navigator.browserLanguage) ? 
navigator.browserLanguage : 
(navigator.language) ? navigator.language : navigator.userLanguage);

Here's a good tutorial on how localization works in Flex:

http://livedocs.adobe.com/flex/3/html/help.html?content=l10n_1.html

As far as detecting the user's region and/or language you can try this in ActionScript:

Capabilities.language

Or perhaps something like this in Javascript (invoked through Flash's ExternalInterface):

var lan = ((navigator.browserLanguage) ? 
navigator.browserLanguage : 
(navigator.language) ? navigator.language : navigator.userLanguage);
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文