473,465 Members | 1,399 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Programatically select which resource file to load from

Hi.

Could anyone help me out with this one.

I have a aspx page from where users may send invites to other users.
When the user clicks the "send invite"-button an email is generated.
Now here's the case:
I'm interested in sending the email in the language chosen by the user.
mail.Body = Resources.iwm.emailBodySendWL;

This would load the corresponding language as given in the @page directive
(UICulture="auto")
But lets say the user is interested in sending an invite in another language
than he/she has in the browsersettings.
Whats the best way to achieve that?

Thanks!

Michael

Aug 26 '08 #1
1 1726
This is not a localization problem, per se, if the user can select the
language to send in. It is a decision point. And, you simply pull the file
that corresponds to the langauge the user selected.

If you want to use resource files for email (not the best choice, but you
can make it work), then pull the text using the localization bits based on
the culture the user is, or selects. As long as you have a resource file in
that language it is fairly easy. This is not the intent of
globalization/localization through resource files, but it is an interesting
usage.

I would suggest looking for Michele Bustamante's work on MSDN, or tune in to
her blog:
http://www.dasblonde.net/

A google search using the site: tag should yield something.

--
Gregory A. Beamer
MVP, MCP: +I, SE, SD, DBA

Subscribe to my blog
http://feeds.feedburner.com/GregoryBeamer#

or just read it:
http://feeds.feedburner.com/GregoryBeamer

********************************************
| Think outside the box! |
********************************************
"Michael" <mi******@broadpark.nowrote in message
news:EA**********************************@microsof t.com...
Hi.

Could anyone help me out with this one.

I have a aspx page from where users may send invites to other users.
When the user clicks the "send invite"-button an email is generated.
Now here's the case:
I'm interested in sending the email in the language chosen by the user.
mail.Body = Resources.iwm.emailBodySendWL;

This would load the corresponding language as given in the @page directive
(UICulture="auto")
But lets say the user is interested in sending an invite in another
language than he/she has in the browsersettings.
Whats the best way to achieve that?

Thanks!

Michael
Aug 27 '08 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: developer | last post by:
I have a Windows form that contains a datagrid populated with a table in my database. When i load my form i want a particular row in my datagrid to be selected. How can i do that Thanks
2
by: Arjen | last post by:
Hello, I have 2 resource files. The resource files have both inside the name field values. I want to select from the first resource file the records where the name field haves a value between 1...
6
by: martin | last post by:
Hi, I have noticed that every aspx page that I created (and ascx file) has an assosiated resource file aspx.resx. However what I would like to do is have a single global resource file for the...
0
by: mike | last post by:
Hi, When I programatically Bind a DataSource to DetailsView it does not fire "ModeChanged" event. This is first time i am trying to use ASP.NET DetailsView control. I have played with some of the...
8
by: John Dunn | last post by:
Since currently we aren't allowed to have compiled XAML files embedded in C++ apps I'm using Markup::XamlReader::Load to dynamically load XAML files. This works perfectly fine with external files...
4
by: carson | last post by:
I have written two windows services: - service A does some crunching of local data files and uploads them to a central processing computer via http. - service B monitors a manifest file on a...
0
by: Jürgen Heyn | last post by:
Good afternoon, I would like to display a bitmap in a PictureBox which is stored in a resource file. The following code works perfectly: picUser.Image =...
2
by: Nesster13 | last post by:
Hi, I am building an application that will utilize the local resource file. Right now the application is separated into two part, the header and the content. One of the line at the top of the...
12
by: TS | last post by:
i have a need to possibly enable mutli language support. What benefit do i get by using a resource file instead of a custom xml solution? thanks!
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.