473,396 Members | 1,970 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

ASP.NET 2.0 : Explicit localization expression

Hello,

I'm trying to use explicit localization expression to access global
resources from an .inc file that's included into several ASPX pages.

I may be wrong in my expression, bu accessing Local resources is working
well indeed. Here is the code :

.....
<asp:Localize runat="server" id='myid' text="<% $ Resources
sharedStrings,title_inc%>">some text</asp:Localize>
.....

Where 'sharedstrings' is the name of a global resource file and 'title_inc'
is the string Name.
In the resource file, we could find a string named "title_inc.Text".

TIA.
Nov 19 '05 #1
1 1711
Hi Olivier,

Welcome to ASPNET newsgroup.
As for the accessing resource strings in global resource files, we can also
make it in the inline aspx databinding expression. For example:

<asp:Label ID="ColumnCurrency" runat="server" Text='<%#
(string)GetGlobalResourceObject("CurrencyNames",(s tring)Eval("Region")) %>'
meta:resourcekey="LabelResource4"></asp:Label>

Here is related the reference on MSDN 2 site:

http://beta.asp.net/QUICKSTART/util/.../samples/local
ization/LocalizeImpExp.src&file=LocalizeImpExp_cs\Localize ImpExp_cs.aspx

Hope helps. Thanks,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)
--------------------
| From: "Olivier Matrot" <ol****************@online.nospam>
| Subject: ASP.NET 2.0 : Explicit localization expression
| Date: Thu, 25 Aug 2005 17:00:36 +0200
| Lines: 20
| X-Priority: 3
| X-MSMail-Priority: Normal
| X-Newsreader: Microsoft Outlook Express 6.00.2900.2180
| X-RFC2646: Format=Flowed; Original
| X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2180
| Message-ID: <#Y**************@TK2MSFTNGP11.phx.gbl>
| Newsgroups: microsoft.public.dotnet.framework.aspnet
| NNTP-Posting-Host: reverse.completel.net 213.30.138.178
| Path: TK2MSFTNGXA01.phx.gbl!TK2MSFTNGP08.phx.gbl!TK2MSFT NGP11.phx.gbl
| Xref: TK2MSFTNGXA01.phx.gbl
microsoft.public.dotnet.framework.aspnet:120270
| X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet
|
| Hello,
|
| I'm trying to use explicit localization expression to access global
| resources from an .inc file that's included into several ASPX pages.
|
| I may be wrong in my expression, bu accessing Local resources is working
| well indeed. Here is the code :
|
| ....
| <asp:Localize runat="server" id='myid' text="<% $ Resources
| sharedStrings,title_inc%>">some text</asp:Localize>
| ....
|
| Where 'sharedstrings' is the name of a global resource file and
'title_inc'
| is the string Name.
| In the resource file, we could find a string named "title_inc.Text".
|
| TIA.
|
|
|

Nov 19 '05 #2

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

Similar topics

1
by: Stub | last post by:
Docs says that "The compiler does not use an explicit constructor to implement an implied conversion of types. It's purpose is reserved explicitly for construction." I put up code of three cases...
6
by: Rental | last post by:
I'm having the sam problem as described below with the Localization toolkit. Does anyone know if there is a solution to this problem. --->When attempting to generate resource dlls with...
1
by: kelmen | last post by:
Greeting, I'm working on the resources stuff, using the explicit localization. And to test it is as : http://www.asp.net/QuickStart/aspnet/doc/localization/culture.aspx#ielanguage add in the...
5
by: CMM | last post by:
I don't seem to "get" ASP.NET 2.0's Localization features. I've read up on everything... and of course, everything is explained in cursory softball terms- not any "real-world" usage way. I hope...
2
by: bruno | last post by:
I need to localize my ASP.NET app and I just used "Tools" --"generate local resources" command and everything works fine in my WebForms. Resource file name is: MyWebForm.aspx.resx under a subDir...
1
by: Rusty Hill | last post by:
My web app is going to support 26 different cultures and languages. I understand how to handle the basic localization. How do I localize the validation controls and expressions that will be used...
0
by: Rusty Hill | last post by:
I am trying to concatenate two localization expressions AT DESIGN TIME and am not sure how to do it. For example I would like to concatenate two pieces of information from resource files and have...
2
by: Chris Walls | last post by:
We have created two (2) global resource files in App_GlobalResouces: Global.resx Global.es-MX.resx In an ASP.NET page, we use two different syntaxes to set text on the page, depending upon the...
12
by: Rahul | last post by:
Hi Everyone, I have the following code and i'm able to invoke the destructor explicitly but not the constructor. and i get a compile time error when i invoke the constructor, why is this so? ...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
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
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
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...
0
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...

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.