Multiple language application with Asp.net 2.0

C++书籍权威指南与列表 C++ 是一门庞大且复杂的编程语言,与许多可通过网上教程快速上手的编程语言不同,若不研读一本优质的 C++ 书籍,很难快速掌握 C++。市面上存在大量质量不佳的 C++ 书籍,这些书不仅风格欠佳,还存在明显的事实性错误,并且倡导糟糕的编程风格。因此,收集优质的 C++ 书籍并按不同技能水平分类推荐显得尤为重要。 阅读详情

I tested the way to make a global application with Asp.net 2.0
Share it now and looking forward to receiving your feedback and directions.

1、Create the resource file in Resources folder

Japanese(SharedResource.ja.resx)


English(SharedResource.en-US.resx)


2、In Global.asax,

 void Application_BeginRequest(object sender, EventArgs e)
    
{
        
if (Request.Params["Language"!= null)
        
{
            
if (Request.Params["Language"].ToString() == "jp")
            
{
                Thread.CurrentThread.CurrentUICulture 
= new CultureInfo("ja");
            }

            
else
            
{
                Thread.CurrentThread.CurrentUICulture 
= new CultureInfo("en-US");
            }

        }

        
else
        
{
            Thread.CurrentThread.CurrentUICulture 
= CultureInfo.CreateSpecificCulture(Request.UserLanguages[0]);
        }

    }


you can see I used a parameter [Language] to swith to different language, certainly we can change the paremeter before
we post to server in aspx.

3、In aspx page_load

        this.lbTop.Text = (string)GetAppResourceObject("SharedResource""Top");
        
this.lbLogOff.Text = (string)GetAppResourceObject("SharedResource""LogOff"
);

Use the method [GetAppResourceObject] we can get the string from resource file.

从零搭建Obsidian智能知识库:Ollama本地模型与Copilot插件实战指南 本文详细介绍了如何从零搭建Obsidian智能知识库,结合Ollama本地模型与Copilot插件实现高效知识管理。通过本地部署AI助手,用户可以在保证隐私安全的同时,快速检索和整理笔记,提升工作效率。文章涵盖硬件准备、Ollama部署、插件配置及实战技巧,适合需要高效知识管理的专业人士。 阅读详情

相关推荐

NVIDIA Isaac GR00T N1 人形机器人强化学习入门教程(二)详细步骤

LeRobot 格式 1.1 加载数据集 要加载数据集,我们需要定义以下 3 项内容: 在数据中显示图像帧 我们还可以对 LeRobotSingleDataset 类中的数据进行一系列转换。下面展示了如何对数据进行转换。 现在看看应用转换后的数据有何不同。 例如,对状态和操作进行规范化和串联,对视频图像进行裁剪、调整大小和颜色抖动。 二、GR00T 推断 本教程介绍如何使用 GR00

2506_90492529的博客 2962

语言本地化的救急解决方案 (非Unicode编码的程序)

我们经常遇到语言本地化的问题,例如,日语的游戏在我们的windows中显示乱码的问题,我们编写的中文程序在英文windows下也可能会显示乱码。最好的解决办法当然是自己做好本地化的策略了。如果时间紧迫,没时间做本地化了该怎么办?使用本地化软件是个不错的选择。微软自家的AppLocale可以解决很多问题,但是它在安装和使用过程中问题依然不少,毕竟是老家伙了。无意间在日语游戏乱码的问题上(千万别问我什么

TC王者专栏 5542

aspose-cells-crack-20.7.zip

excel文件转pdf

ASP.Net本地化/国际化解决方案原理和代码示例

解决方案原理:ASP.NET本地化支持 通过 CultureInfo 类可以访问区域设置的属性。此外,ASP.NET 基于每个线程和请求跟踪默认区域性的两个属性:用于区域设置相关函数默认值的 CurrentCulture,和用于区域设置特定的资源数据查找的 CurrentUICulture。 解决方案主要包含几个部分组成:1:客户设置语言的控件,一般会包含在每个页面,使得用户可以随时切换区域控件a...

weixin_33853827的博客 267

IOS應用程序多語言本地化解决方案

苹果官方的本地化方法:http://developer.apple.com/library/ios/#referencelibrary/GettingStarted/RoadMapiOSCh/chapters/InternationalizeYourApp/ 民间的本地化方法:http://rritw.com/a/caozuoxitong/OS/20120817/206250.html 这个介

fanxiaochuan的专栏 653

2019前端书籍推荐,前端PDF书籍,前端书籍下载

 因前端知识面太大,每人、每个公司的技术体系各不相同,本文并不推荐哪些前端书籍更值得阅读,只是描述下简单信息,以分享的方式把这些书籍共享出来,大家可自行选择。         因书籍过多,本文会陆续更新,有需要什么书籍的朋友可评论留言,下次更新会附上该书籍下载地址。   目录 HTML5相关书籍  CSS相关书籍 jQuery相关书籍  JavaScrip相关书籍 ES6,Vue H...

群来群往的博客 7594

嵌入式Linux必读经典书籍

最近,在知乎看到一个问题,“嵌入式Linux有哪些好书推荐”。我读研期间也喜欢收藏一些书籍,每次看到京东有活动,总是忍不住想买一些书籍回来。 随着时间越来越久,我买的书越来越多,但是都看完不太现实。后来发现书不在于多,而在于经典。 买了书搬家是个麻烦事,我从网上搜集了一套计算机电子书,从中筛选了我看过的好书分享给大家。 在这里我推荐我看过的比较好的书,从入门到进阶。 这是我上学期间买过的一些书,其中的很大一部分还没看完: 我整理的这些书大家可以在这里免费白嫖,都是嵌入式领域的经典书籍,从入门到深入理解,整理

嵌入式与Linux那些事的博客 6215

十本经典JavaScript书籍

十本经典JavaScript书籍 同步滚动: 一:《JavaScript权威指南(第六版)》 这本书是程序员学习核心JavaScript语言和由Web浏览器定义的JavaScript API的指南和综合参考手册。第6版涵盖HTML 5和ECMAScript 5。很多章节完全重写,以便与时俱进,紧跟当今的最佳Web开发实践。本书新增章节描述了jQuery和服务器端JavaScript。适合那些希望学习Web编程语言的初、中级程序员和希望精通JavaScript的JavaScript程序员阅读。 i

前端视听 2万+

自学python书籍推荐,请多多列举?

最喜欢的一个学习方法,时常整理自己的笔记,尝试把自己的笔记转成文章输出出来,放在网络博客,简书或者CSDN等技术论坛上. 在输出的同时,在追求完美的同时,就会发现自己的不足,搜罗各种知识点,结合自己的理解.不用怕发对不对,有热心网友会指出你的问题,这样更能刺激你去主动学习。最新Python教程,8天python从入门到精通,学python看这套就够了_哔哩哔哩_bilibili。2022年大数据spark3.2入门。2022年hadoop3.x入门。2022年MySQL基础入门。

m0_57290404的博客 763

Happy birthday to my mother

Today is my mothers birthday, I called mother for her birthday.I havent go back home for more than one year,may be I am an unfilial son.My hometown is a very small county seat, for the youth there l

Flyinsky 1390

Japanese business glossary -- Kangei-kai and Sobetsu-kai

I want to introduce some Japanese business glossary here.The frequent holding of kangei-kai(welcoming party) by businessmen as wellas by people in other walks of life, is one of the ways in which the

Flyinsky 1208

American dream

I watched several American movies today, I am sorry to say I download them frominternet, they are piratical.From the movies, I can know something about the American life and her culture,and I like the

Flyinsky 1135

Mourning for the people lost in the Second World War

In the morning today , a convocation was came off  in Japan for mourning forthe people lost in the Second World War.Every year in Japan there will be lots of movements like this to mourning,it looks l

Flyinsky 981

Unable to debug in VS2003 after installing VS2005

I was unable to debug asp.net project in VS2003 today,because I installed VS2005 Beta.There is a error message that I got************************Microsoft Development Environment********************

Flyinsky 979

a day of a programmer

There are many articles in CSDN about the life of programmer.I drew mine.6:00      The bell rang, stop it and go on sleeping.6:10~6:15  Get up, go to rest room and get a cup of water.6:15~7:00  En

Flyinsky 975

Gmail = blog?

A guy turns Gmail into blogging tool, this is the link.It is a cool idea . 1GB of email storage space only for email sounds waste.

Flyinsky 947

RSS2.0 Reader

I have begun to blog for almost 7 months, but I have never used a RSS reader softeware,I always use the .Net Framework sdk help browser, because it shows only one button in taskbar.I know there are lo

Flyinsky 924

telephone conference

Yesterday I joined a international telephone conference and tomorrow will another one.The other party was from Europe, absolutely english was used, embarrassedly I can not understand all what they sai

Flyinsky 920
上一篇: earthquake and typhoon
下一篇: telephone conference
tomyao
博客等级 码龄25年 0粉丝 31原创
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值