473,378 Members | 1,380 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,378 software developers and data experts.

Dreamweaver using .resource files

I am just investigating on .resx and .resource files using asp.net. I
am attempting to develop a webpage in Dreamweaver on an asp.net
webserver. As i read around the net, using a .resource file for all
my text on my website seems like the best way to go. I would just
have a fr.resource file for each language. This seems like it would
work pretty well. I have been able to create the .resource files but
i do not know how to read them to put on my website. Most of the
information i have been reading explains how to do this with VBstudio,
but i am using dreamworks. Can someone point me in the right
direction?

May 29 '07 #1
2 1986
If this is page by page, you do the following:

1. Create a directory called App_LocalResources
2. Name the resource file for default.aspx default.aspx.resx
3. Use the following tag to get the value Header from this file (assuming a
name of HeaderText)

<%$ Resources:HeaderText %>

as in

<h1><asp:Label runat="server" Text="<%$ Resources:HeaderText %>"
id="Label3"/></h1>

For global resources

1. Create a directory called App_GlobalResources
2. Name the file something like GlobalResources.resx (name not as important
as matching the file name to the class name in the next step)
3. Use the following tag (note the GlobalResources class name as this is the
major change from local resources)

<%$ Resources:GlobalResources, HeaderText %>

as in

<h1><asp:Label runat="server" Text="<%$ Resources:GlobalResources,
HeaderText %>" id="Label3"/></h1>

Rule: ClassName = RESX file name.

If you do this, ASP.NET can be set up to automatically localize content when
you have the proper language resource files. You will have to add a
globalization tag to the web.config.

For a great intro, find Michele Leroux Bustamante's articles on MSDN. You
can also find her blog at www.dasblonde.com.

--
Gregory A. Beamer
MVP; MCP: +I, SE, SD, DBA
http://gregorybeamer.spaces.live.com
Co-author: Microsoft Expression Web Bible (upcoming)

************************************************
Think outside the box!
************************************************
"Daniel" <da**********@gmail.comwrote in message
news:11**********************@o5g2000hsb.googlegro ups.com...
>I am just investigating on .resx and .resource files using asp.net. I
am attempting to develop a webpage in Dreamweaver on an asp.net
webserver. As i read around the net, using a .resource file for all
my text on my website seems like the best way to go. I would just
have a fr.resource file for each language. This seems like it would
work pretty well. I have been able to create the .resource files but
i do not know how to read them to put on my website. Most of the
information i have been reading explains how to do this with VBstudio,
but i am using dreamworks. Can someone point me in the right
direction?

May 30 '07 #2
That didn't work for me. My site just displayed "<%$
Resources:GlobalResources,
HeaderText %>" in <h1format. My asp server compiles other code. Do
you know what the problem could be?
thanks!

Jun 11 '07 #3

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

Similar topics

11
by: jm | last post by:
Somebody on here recommended Dreamweaver with PHP. I am coming from (still using really) ASP and ASP.NET. PHP is more like ASP and not a whole lot like .net, but I wanted to know how Dreamweaver...
5
by: I.P. Freely | last post by:
Hi, I've been using Visual Studio.NET for a while to design WinForms and Console apps and love it. Recently I had to a WebForms app. Because I have no artistic skill whatsoever, I enlisted the...
0
by: James Zhuo | last post by:
hi all I changed the name of the class LoginPage to a different name "LoginPageOne" But the same error gets generated with the Wiliam.Request.LoginPageOne. That pretty much leaves me clueless...
4
by: Ian | last post by:
Hi there, Has anybody got any tips or recommendations for using Vs.Net and Dreamweaver 2004 together? I like to use dreamweaver as the layout tool as for me it just seems a little more...
1
by: Art Vandelay | last post by:
Does anyone have any real world experience or recommendations of how to let our hardcore designers use Dreamweaver, CSS, and Templates(the pretty part) while letting our hardcore programmers...
4
by: Adam Knight | last post by:
Hi all, I am using a dreamweaver template for a web app i am working on. Each time i update the template my page directives at the top of the associated pages gets removed. Anyone had...
4
by: TCook | last post by:
Hey All, I am building a solution which will have many strings that will need to be localized (i.e. strings for toolbars, strings for different WinForms, strings for messages and error messages,...
2
by: Andrus | last post by:
I have resource files in different languages created by VCS 2005 Express. I want to use those files to translate reports at runtime. I have text to be translated as string. I think I need to...
1
by: Rishi Boparai | last post by:
I'm using Dreamweaver to create the layout and manage my ASP.net 2 site. However, all ""code-behind"" is done in Visual Studio 2005 On my ASP.net pages I need to have a different declaration at...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
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
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

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.