what are aspx.resx files for?

H

Hans Kesting

Hi,

When I add a webform, VS generates three files:

WebForm1.aspx
WebForm1.aspx.cs (could also be "WebForm1.aspx.vb" I guess)
WebForm1.aspx.resx

What is that last file for? How can I use it?
I understand the use of (but haven't used yet..) the "stand alone" resource
files
but have not been able to find a reference to this webform-specific file.


Hans Kesting
 
J

Jim Cheshire [MSFT]

Hi Hans,

The most common use of resource files is to hold localization information
so that you can present different versions of your application depending on
the locale. However, there are other uses as well.

http://samples.gotdotnet.com/quickstart/aspplus/doc/resourcefiles.aspx

Jim Cheshire, MCSE, MCSD [MSFT]
ASP.NET
Developer Support
(e-mail address removed)

This post is provided as-is with no warranties and confers no rights.

--------------------
 
H

Hans Kesting

Yes, I know.

You can instantiate a ResourceManager, that you point to a set of resource
files,
(for the different supported cultures). Then it is possible te retrieve
texts and
binary information as specific as possible for the current culture.

However, the question was (or was supposed to be, might have been unclear):
how can I use specifically the aspx.resx files that are generated
automatically?
Just as "regular" resource files (add more of those files for the supported
cultures,
instantiate a ResourceManager, point it to the set of resource files, and
use it
for every text that is culture specific; in short: add a lot of coding)
or is there any direct support built-in, which requires (almost) no coding?
(I can imagine a feature where label-texts and so on are automatically
replaced by a text from the resource, if the label-text happens to be an
existing resource-label)


Hans Kesting


Jim Cheshire said:
Hi Hans,

The most common use of resource files is to hold localization information
so that you can present different versions of your application depending on
the locale. However, there are other uses as well.

http://samples.gotdotnet.com/quickstart/aspplus/doc/resourcefiles.aspx

Jim Cheshire, MCSE, MCSD [MSFT]
ASP.NET
Developer Support
(e-mail address removed)

This post is provided as-is with no warranties and confers no rights.

--------------------
From: "Hans Kesting" <[email protected]>
Subject: what are aspx.resx files for?
Date: Mon, 9 Feb 2004 10:41:14 +0100
Lines: 17
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
Message-ID: <#[email protected]>
Newsgroups: microsoft.public.dotnet.framework.aspnet
NNTP-Posting-Host: 62.166.159.254
Path:
cpmsftngxa07.phx.gbl!cpmsftngxa06.phx.gbl!TK2MSFTNGP08.phx.gbl!TK2MSFTNGP12.
phx.gbl
Xref: cpmsftngxa07.phx.gbl microsoft.public.dotnet.framework.aspnet:208516
X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet

Hi,

When I add a webform, VS generates three files:

WebForm1.aspx
WebForm1.aspx.cs (could also be "WebForm1.aspx.vb" I guess)
WebForm1.aspx.resx

What is that last file for? How can I use it?
I understand the use of (but haven't used yet..) the "stand alone" resource
files
but have not been able to find a reference to this webform-specific file.


Hans Kesting
 
J

Jim Cheshire [MSFT]

Hans,

I am really not following you here. Can you explicitly indicate what you
mean by "use"?

Jim Cheshire, MCSE, MCSD [MSFT]
ASP.NET
Developer Support
(e-mail address removed)

This post is provided as-is with no warranties and confers no rights.

--------------------
From: "Hans Kesting" <[email protected]>
References: <#[email protected]>
Subject: Re: what are aspx.resx files for?
Date: Tue, 10 Feb 2004 11:41:04 +0100
Lines: 85
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
Message-ID: <[email protected]>
Newsgroups: microsoft.public.dotnet.framework.aspnet
NNTP-Posting-Host: 62.166.159.254
Path: cpmsftngxa07.phx.gbl!cpmsftngxa10.phx.gbl!TK2MSFTNGXA05.phx.gbl!TK2MSFTNGP08
..phx.gbl!tk2msftngp13.phx.gbl
Xref: cpmsftngxa07.phx.gbl microsoft.public.dotnet.framework.aspnet:208840
X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet

Yes, I know.

You can instantiate a ResourceManager, that you point to a set of resource
files,
(for the different supported cultures). Then it is possible te retrieve
texts and
binary information as specific as possible for the current culture.

However, the question was (or was supposed to be, might have been unclear):
how can I use specifically the aspx.resx files that are generated
automatically?
Just as "regular" resource files (add more of those files for the supported
cultures,
instantiate a ResourceManager, point it to the set of resource files, and
use it
for every text that is culture specific; in short: add a lot of coding)
or is there any direct support built-in, which requires (almost) no coding?
(I can imagine a feature where label-texts and so on are automatically
replaced by a text from the resource, if the label-text happens to be an
existing resource-label)


Hans Kesting


Jim Cheshire said:
Hi Hans,

The most common use of resource files is to hold localization information
so that you can present different versions of your application depending on
the locale. However, there are other uses as well.

http://samples.gotdotnet.com/quickstart/aspplus/doc/resourcefiles.aspx

Jim Cheshire, MCSE, MCSD [MSFT]
ASP.NET
Developer Support
(e-mail address removed)

This post is provided as-is with no warranties and confers no rights.

--------------------
From: "Hans Kesting" <[email protected]>
Subject: what are aspx.resx files for?
Date: Mon, 9 Feb 2004 10:41:14 +0100
Lines: 17
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
Message-ID: <#[email protected]>
Newsgroups: microsoft.public.dotnet.framework.aspnet
NNTP-Posting-Host: 62.166.159.254
Path:
cpmsftngxa07.phx.gbl!cpmsftngxa06.phx.gbl!TK2MSFTNGP08.phx.gbl!TK2MSFTNGP12
 
H

Hans Kesting

I think the question really is "WHY are these files generated along with
aspx and ascx files?".
It's probably not just to take up space so there is a reason why they are
generated.
WHAT is that reason?
Does some component inside the asp.net system (or maybe the IDE, because
that's the one
generating these files) need these files?
If so, what components and for what use?

And along with the above questions there is "can *I* change anything there
to
do something usefull within my application"?

Hans Kesting


Jim Cheshire said:
Hans,

I am really not following you here. Can you explicitly indicate what you
mean by "use"?

Jim Cheshire, MCSE, MCSD [MSFT]
ASP.NET
Developer Support
(e-mail address removed)

This post is provided as-is with no warranties and confers no rights.

--------------------
From: "Hans Kesting" <[email protected]>
References: <#[email protected]>
Subject: Re: what are aspx.resx files for?
Date: Tue, 10 Feb 2004 11:41:04 +0100
Lines: 85
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
Message-ID: <[email protected]>
Newsgroups: microsoft.public.dotnet.framework.aspnet
NNTP-Posting-Host: 62.166.159.254
Path:
cpmsftngxa07.phx.gbl!cpmsftngxa10.phx.gbl!TK2MSFTNGXA05.phx.gbl!TK2MSFTNGP08
phx.gbl!tk2msftngp13.phx.gbl
Xref: cpmsftngxa07.phx.gbl microsoft.public.dotnet.framework.aspnet:208840
X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet

Yes, I know.

You can instantiate a ResourceManager, that you point to a set of resource
files,
(for the different supported cultures). Then it is possible te retrieve
texts and
binary information as specific as possible for the current culture.

However, the question was (or was supposed to be, might have been unclear):
how can I use specifically the aspx.resx files that are generated
automatically?
Just as "regular" resource files (add more of those files for the supported
cultures,
instantiate a ResourceManager, point it to the set of resource files, and
use it
for every text that is culture specific; in short: add a lot of coding)
or is there any direct support built-in, which requires (almost) no coding?
(I can imagine a feature where label-texts and so on are automatically
replaced by a text from the resource, if the label-text happens to be an
existing resource-label)


Hans Kesting


Jim Cheshire said:
Hi Hans,

The most common use of resource files is to hold localization information
so that you can present different versions of your application
depending
on
the locale. However, there are other uses as well.

http://samples.gotdotnet.com/quickstart/aspplus/doc/resourcefiles.aspx

Jim Cheshire, MCSE, MCSD [MSFT]
ASP.NET
Developer Support
(e-mail address removed)

This post is provided as-is with no warranties and confers no rights.

--------------------
From: "Hans Kesting" <[email protected]>
Subject: what are aspx.resx files for?
Date: Mon, 9 Feb 2004 10:41:14 +0100
Lines: 17
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
Message-ID: <#[email protected]>
Newsgroups: microsoft.public.dotnet.framework.aspnet
NNTP-Posting-Host: 62.166.159.254
Path:

cpmsftngxa07.phx.gbl!cpmsftngxa06.phx.gbl!TK2MSFTNGP08.phx.gbl!TK2MSFTNGP12
 
J

Jim Cheshire [MSFT]

Hans,

The IDE uses the resource files to store internal information regarding the
Server Controls on the Web form. You should not add your own information
into the auto-generated resource files.

If you want to use resource files in your application, you should create
your own.

Jim Cheshire, MCSE, MCSD [MSFT]
ASP.NET
Developer Support
(e-mail address removed)

This post is provided as-is with no warranties and confers no rights.

--------------------
From: "Hans Kesting" <[email protected]>
References: <#[email protected]>
<[email protected]>
Subject: Re: what are aspx.resx files for?
Date: Thu, 12 Feb 2004 16:42:56 +0100
Lines: 120
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
Message-ID: <#[email protected]>
Newsgroups: microsoft.public.dotnet.framework.aspnet
NNTP-Posting-Host: 62.166.159.254
Path: cpmsftngxa07.phx.gbl!cpmsftngxa10.phx.gbl!TK2MSFTNGXA05.phx.gbl!TK2MSFTNGP08
.phx.gbl!TK2MSFTNGP11.phx.gbl
Xref: cpmsftngxa07.phx.gbl microsoft.public.dotnet.framework.aspnet:209614
X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet

I think the question really is "WHY are these files generated along with
aspx and ascx files?".
It's probably not just to take up space so there is a reason why they are
generated.
WHAT is that reason?
Does some component inside the asp.net system (or maybe the IDE, because
that's the one
generating these files) need these files?
If so, what components and for what use?

And along with the above questions there is "can *I* change anything there
to
do something usefull within my application"?

Hans Kesting


Jim Cheshire said:
Hans,

I am really not following you here. Can you explicitly indicate what you
mean by "use"?

Jim Cheshire, MCSE, MCSD [MSFT]
ASP.NET
Developer Support
(e-mail address removed)

This post is provided as-is with no warranties and confers no rights.

--------------------
From: "Hans Kesting" <[email protected]>
References: <#[email protected]>
Subject: Re: what are aspx.resx files for?
Date: Tue, 10 Feb 2004 11:41:04 +0100
Lines: 85
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
Message-ID: <[email protected]>
Newsgroups: microsoft.public.dotnet.framework.aspnet
NNTP-Posting-Host: 62.166.159.254
Path:
cpmsftngxa07.phx.gbl!cpmsftngxa10.phx.gbl!TK2MSFTNGXA05.phx.gbl!TK2MSFTNGP0 8
phx.gbl!tk2msftngp13.phx.gbl
Xref: cpmsftngxa07.phx.gbl microsoft.public.dotnet.framework.aspnet:208840
X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet

Yes, I know.

You can instantiate a ResourceManager, that you point to a set of resource
files,
(for the different supported cultures). Then it is possible te retrieve
texts and
binary information as specific as possible for the current culture.

However, the question was (or was supposed to be, might have been unclear):
how can I use specifically the aspx.resx files that are generated
automatically?
Just as "regular" resource files (add more of those files for the supported
cultures,
instantiate a ResourceManager, point it to the set of resource files, and
use it
for every text that is culture specific; in short: add a lot of coding)
or is there any direct support built-in, which requires (almost) no coding?
(I can imagine a feature where label-texts and so on are automatically
replaced by a text from the resource, if the label-text happens to be an
existing resource-label)


Hans Kesting


Hi Hans,

The most common use of resource files is to hold localization information
so that you can present different versions of your application depending
on
the locale. However, there are other uses as well.

http://samples.gotdotnet.com/quickstart/aspplus/doc/resourcefiles.aspx

Jim Cheshire, MCSE, MCSD [MSFT]
ASP.NET
Developer Support
(e-mail address removed)

This post is provided as-is with no warranties and confers no rights.

--------------------
From: "Hans Kesting" <[email protected]>
Subject: what are aspx.resx files for?
Date: Mon, 9 Feb 2004 10:41:14 +0100
Lines: 17
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
Message-ID: <#[email protected]>
Newsgroups: microsoft.public.dotnet.framework.aspnet
NNTP-Posting-Host: 62.166.159.254
Path:

cpmsftngxa07.phx.gbl!cpmsftngxa06.phx.gbl!TK2MSFTNGP08.phx.gbl!TK2MSFTNGP1
2
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,744
Messages
2,569,484
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top