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! 12 5228
TS wrote:
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!
I don't know what your "customer xml solution" is ? You store all
information of controls such as text, color value (#aabbcc) in a regular
xml file, doesn't you ?
As far as I know, ASP.NET support resource file very well. So you
either need a multi languages or not, you should use Resource Feature in
your ASP.NET.
yes.
do you know of the actual benefits of resource file instead of regular xml
file?
"Duy Lam" <du**********@gmail.comwrote in message
news:eA**************@TK2MSFTNGP05.phx.gbl...
TS wrote:
>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!
I don't know what your "customer xml solution" is ? You store all
information of controls such as text, color value (#aabbcc) in a regular
xml file, doesn't you ?
As far as I know, ASP.NET support resource file very well. So you either
need a multi languages or not, you should use Resource Feature in your
ASP.NET.
Hi TS,
I think the main advantage of using .NET resource file(or resx file) is
that you can make full use of the built-in API or coding syntax support.
For example, .NET provide "ResourceManager Class" to help you
programmatically load resource keys from resource file or resx file. Also,
..net resource file can be embeded into assembly. If you're using custom
xml solution, you'll need to define your own xml file format and use raw
XML API to manipulate them. How do you think?
Sincerely,
Steven Cheng
Microsoft MSDN Online Support Lead
This posting is provided "AS IS" with no warranties, and confers no rights.
--------------------
>From: "TS" <ma**********@nospam.nospam> References: <OL**************@TK2MSFTNGP03.phx.gbl>
<eA**************@TK2MSFTNGP05.phx.gbl>
>Subject: Re: Resource file vs. regular Xml file Date: Wed, 14 Nov 2007 12:00:41 -0600
yes.
do you know of the actual benefits of resource file instead of regular xml file?
"Duy Lam" <du**********@gmail.comwrote in message news:eA**************@TK2MSFTNGP05.phx.gbl...
>TS wrote:
>>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!
I don't know what your "customer xml solution" is ? You store all information of controls such as text, color value (#aabbcc) in a regular xml file, doesn't you ? As far as I know, ASP.NET support resource file very well. So you
either
>need a multi languages or not, you should use Resource Feature in your ASP.NET.
do you know of the actual benefits of resource file instead of regular xml
file?
First, what is the benefit of your own XML files?
The standard resources are, well, standard.
Most translation tools will know about them, some translators might know
about them, and so on.
Many people used them successfully, so it is a tried solution, working,
with some known problems and known work-arounds.
Which is probably not the case with a proprietary format.
--
Mihai Nita [Microsoft MVP, Windows - SDK] http://www.mihai-nita.net
------------------------------------------
Replace _year_ with _ to get the real email
thank you.
One concern i never asked was caching. currently i am caching my custom xml
files. Do resource files get cached or need caching?
If for example my application was deployed and then we found out there was a
spelling mistake, I imaging we could manually update the resource file? In
this scenario, how does caching play in?
thanks~!
"Steven Cheng[MSFT]" <st*****@online.microsoft.comwrote in message
news:ZR**************@TK2MSFTNGHUB02.phx.gbl...
Hi TS,
I think the main advantage of using .NET resource file(or resx file) is
that you can make full use of the built-in API or coding syntax support.
For example, .NET provide "ResourceManager Class" to help you
programmatically load resource keys from resource file or resx file.
Also,
net resource file can be embeded into assembly. If you're using custom
xml solution, you'll need to define your own xml file format and use raw
XML API to manipulate them. How do you think?
Sincerely,
Steven Cheng
Microsoft MSDN Online Support Lead
This posting is provided "AS IS" with no warranties, and confers no
rights.
--------------------
>>From: "TS" <ma**********@nospam.nospam> References: <OL**************@TK2MSFTNGP03.phx.gbl>
<eA**************@TK2MSFTNGP05.phx.gbl>
>>Subject: Re: Resource file vs. regular Xml file Date: Wed, 14 Nov 2007 12:00:41 -0600
yes.
do you know of the actual benefits of resource file instead of regular xml file?
"Duy Lam" <du**********@gmail.comwrote in message news:eA**************@TK2MSFTNGP05.phx.gbl...
>>TS wrote: 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!
I don't know what your "customer xml solution" is ? You store all information of controls such as text, color value (#aabbcc) in a regular xml file, doesn't you ? As far as I know, ASP.NET support resource file very well. So you
either
>>need a multi languages or not, you should use Resource Feature in your ASP.NET.
Thanks for your followup TS,
If you're using .net resource model(resource file or embeded in assembly),
then, you should not change them frequently or dynamically at runtime.
Because when .net application running, the resource items will be loaded
into memory after it is used, just like it load the required assemblies.
Therefore, it won't let you to flexibly update and refresh it immediately
if you changed them when the application is running.
BTW, if you want to implement your own resource model and component, maybe
you can havea look at the following article which introducing extending the
.NET resource provider:
#Extending the ASP.NET 2.0 Resource-Provider Model http://msdn2.microsoft.com/en-us/library/aa905797.aspx
Sincerely,
Steven Cheng
Microsoft MSDN Online Support Lead
This posting is provided "AS IS" with no warranties, and confers no rights.
--------------------
>From: "TS" <ma**********@nospam.nospam> References: <OL**************@TK2MSFTNGP03.phx.gbl>
<eA**************@TK2MSFTNGP05.phx.gbl>
<uU**************@TK2MSFTNGP02.phx.gbl>
<ZR**************@TK2MSFTNGHUB02.phx.gbl>
>Subject: Re: Resource file vs. regular Xml file Date: Thu, 15 Nov 2007 08:15:57 -0600
> thank you.
One concern i never asked was caching. currently i am caching my custom
xml
>files. Do resource files get cached or need caching?
If for example my application was deployed and then we found out there was
a
>spelling mistake, I imaging we could manually update the resource file? In this scenario, how does caching play in?
thanks~!
"Steven Cheng[MSFT]" <st*****@online.microsoft.comwrote in message news:ZR**************@TK2MSFTNGHUB02.phx.gbl...
>Hi TS,
I think the main advantage of using .NET resource file(or resx file) is that you can make full use of the built-in API or coding syntax support. For example, .NET provide "ResourceManager Class" to help you programmatically load resource keys from resource file or resx file. Also, net resource file can be embeded into assembly. If you're using custom xml solution, you'll need to define your own xml file format and use raw XML API to manipulate them. How do you think?
Sincerely,
Steven Cheng
Microsoft MSDN Online Support Lead
This posting is provided "AS IS" with no warranties, and confers no rights.
--------------------
>>>From: "TS" <ma**********@nospam.nospam> References: <OL**************@TK2MSFTNGP03.phx.gbl>
<eA**************@TK2MSFTNGP05.phx.gbl>
>>>Subject: Re: Resource file vs. regular Xml file Date: Wed, 14 Nov 2007 12:00:41 -0600
yes.
do you know of the actual benefits of resource file instead of regular
xml
>>>file?
"Duy Lam" <du**********@gmail.comwrote in message news:eA**************@TK2MSFTNGP05.phx.gbl... TS wrote: 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!
I don't know what your "customer xml solution" is ? You store all information of controls such as text, color value (#aabbcc) in a
regular
>>>xml file, doesn't you ? As far as I know, ASP.NET support resource file very well. So you
either
>>>need a multi languages or not, you should use Resource Feature in your ASP.NET.
steven, are resource files 1 per application or can they be split up to have
many, say 1 per 10 pages of an application. IF so is there any reason to
do/not do this?
thanks!!!!
"Steven Cheng[MSFT]" <st*****@online.microsoft.comwrote in message
news:J2**************@TK2MSFTNGHUB02.phx.gbl...
Thanks for your followup TS,
If you're using .net resource model(resource file or embeded in assembly),
then, you should not change them frequently or dynamically at runtime.
Because when .net application running, the resource items will be loaded
into memory after it is used, just like it load the required assemblies.
Therefore, it won't let you to flexibly update and refresh it immediately
if you changed them when the application is running.
BTW, if you want to implement your own resource model and component, maybe
you can havea look at the following article which introducing extending
the
NET resource provider:
#Extending the ASP.NET 2.0 Resource-Provider Model http://msdn2.microsoft.com/en-us/library/aa905797.aspx
Sincerely,
Steven Cheng
Microsoft MSDN Online Support Lead
This posting is provided "AS IS" with no warranties, and confers no
rights.
--------------------
>>From: "TS" <ma**********@nospam.nospam> References: <OL**************@TK2MSFTNGP03.phx.gbl>
<eA**************@TK2MSFTNGP05.phx.gbl>
<uU**************@TK2MSFTNGP02.phx.gbl>
<ZR**************@TK2MSFTNGHUB02.phx.gbl>
>>Subject: Re: Resource file vs. regular Xml file Date: Thu, 15 Nov 2007 08:15:57 -0600
>> thank you.
One concern i never asked was caching. currently i am caching my custom
xml
>>files. Do resource files get cached or need caching?
If for example my application was deployed and then we found out there was
a
>>spelling mistake, I imaging we could manually update the resource file? In this scenario, how does caching play in?
thanks~!
"Steven Cheng[MSFT]" <st*****@online.microsoft.comwrote in message news:ZR**************@TK2MSFTNGHUB02.phx.gbl.. .
>>Hi TS,
I think the main advantage of using .NET resource file(or resx file) is that you can make full use of the built-in API or coding syntax support. For example, .NET provide "ResourceManager Class" to help you programmatically load resource keys from resource file or resx file. Also, net resource file can be embeded into assembly. If you're using custom xml solution, you'll need to define your own xml file format and use raw XML API to manipulate them. How do you think?
Sincerely,
Steven Cheng
Microsoft MSDN Online Support Lead
This posting is provided "AS IS" with no warranties, and confers no rights.
-------------------- From: "TS" <ma**********@nospam.nospam> References: <OL**************@TK2MSFTNGP03.phx.gbl> <eA**************@TK2MSFTNGP05.phx.gbl> Subject: Re: Resource file vs. regular Xml file Date: Wed, 14 Nov 2007 12:00:41 -0600
yes.
do you know of the actual benefits of resource file instead of regular
xml
>>>>file?
"Duy Lam" <du**********@gmail.comwrote in message news:eA**************@TK2MSFTNGP05.phx.gbl.. . TS wrote: >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! > I don't know what your "customer xml solution" is ? You store all information of controls such as text, color value (#aabbcc) in a
regular
>>>>xml file, doesn't you ? As far as I know, ASP.NET support resource file very well. So you either need a multi languages or not, you should use Resource Feature in your ASP.NET.
Thanks for your reply TS,
For resource file, normally you will add them into project through the
following means:
** You add a resource xml file(resx file) which can contain different kind
of resource objects(string, image, file .....). So you can add multiple
such resx files in a project. When you build the project, they will be
compiled(as embeded resource) into your assembly(or separate satellite
assemlies that contains resource for specific cultures).
For these kinds of resource, you'll use API to get resource item from
it(from assembly).
#Introduction to Resources and Localization http://msdn2.microsoft.com/en-us/lib...93(VS.71).aspx
#Resources in Applications http://msdn2.microsoft.com/en-us/lib...5x(vs.71).aspx
** For ASP.NET application, it has some further encapsulated functionality.
You can provide a local resource file for each aspx page or serveral global
resource files for the entire application. These resource items are easy
to reference in your aspx page(both through declarative syntax or
programatic code):
#using localization resource in ASP.NET: http://quickstarts.asp.net/QuickStar...on/localizatio
n.aspx
Sincerely,
Steven Cheng
Microsoft MSDN Online Support Lead
This posting is provided "AS IS" with no warranties, and confers no rights.
--------------------
>From: "TS" <ma**********@nospam.nospam> Subject: Re: Resource file vs. regular Xml file Date: Mon, 19 Nov 2007 16:42:09 -0600
steven, are resource files 1 per application or can they be split up to
have
>many, say 1 per 10 pages of an application. IF so is there any reason to do/not do this?
thanks!!!!
"Steven Cheng[MSFT]" <st*****@online.microsoft.comwrote in message news:J2**************@TK2MSFTNGHUB02.phx.gbl...
>Thanks for your followup TS,
If you're using .net resource model(resource file or embeded in
assembly),
>then, you should not change them frequently or dynamically at runtime. Because when .net application running, the resource items will be loaded into memory after it is used, just like it load the required assemblies. Therefore, it won't let you to flexibly update and refresh it immediately if you changed them when the application is running.
BTW, if you want to implement your own resource model and component,
maybe
>you can havea look at the following article which introducing extending the NET resource provider:
#Extending the ASP.NET 2.0 Resource-Provider Model http://msdn2.microsoft.com/en-us/library/aa905797.aspx
Sincerely,
Steven Cheng
Microsoft MSDN Online Support Lead
This posting is provided "AS IS" with no warranties, and confers no rights.
--------------------
>>>From: "TS" <ma**********@nospam.nospam> References: <OL**************@TK2MSFTNGP03.phx.gbl>
<eA**************@TK2MSFTNGP05.phx.gbl> <uU**************@TK2MSFTNGP02.phx.gbl> <ZR**************@TK2MSFTNGHUB02.phx.gbl>
>>>Subject: Re: Resource file vs. regular Xml file Date: Thu, 15 Nov 2007 08:15:57 -0600
>>> thank you.
One concern i never asked was caching. currently i am caching my custom
xml
>>>files. Do resource files get cached or need caching?
If for example my application was deployed and then we found out there
was
>a
>>>spelling mistake, I imaging we could manually update the resource file?
In
>>>this scenario, how does caching play in?
thanks~!
"Steven Cheng[MSFT]" <st*****@online.microsoft.comwrote in message news:ZR**************@TK2MSFTNGHUB02.phx.gbl. .. Hi TS,
I think the main advantage of using .NET resource file(or resx file) is that you can make full use of the built-in API or coding syntax
support.
>>>For example, .NET provide "ResourceManager Class" to help you programmatically load resource keys from resource file or resx file. Also, net resource file can be embeded into assembly. If you're using custom xml solution, you'll need to define your own xml file format and use
raw
>>>XML API to manipulate them. How do you think?
Sincerely,
Steven Cheng
Microsoft MSDN Online Support Lead
This posting is provided "AS IS" with no warranties, and confers no rights.
-------------------- >From: "TS" <ma**********@nospam.nospam> >References: <OL**************@TK2MSFTNGP03.phx.gbl> <eA**************@TK2MSFTNGP05.phx.gbl> >Subject: Re: Resource file vs. regular Xml file >Date: Wed, 14 Nov 2007 12:00:41 -0600 > >yes. > >do you know of the actual benefits of resource file instead of regular
xml
>>>>>file? > >"Duy Lam" <du**********@gmail.comwrote in message >news:eA**************@TK2MSFTNGP05.phx.gbl. .. >TS wrote: >>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! >> >I don't know what your "customer xml solution" is ? You store all >information of controls such as text, color value (#aabbcc) in a
regular
>>>>>xml file, doesn't you ? >As far as I know, ASP.NET support resource file very well. So you either >need a multi languages or not, you should use Resource Feature in
your
>>>>>ASP.NET. > > >
thanks steven
"Steven Cheng[MSFT]" <st*****@online.microsoft.comwrote in message
news:YO**************@TK2MSFTNGHUB02.phx.gbl...
Thanks for your reply TS,
For resource file, normally you will add them into project through the
following means:
** You add a resource xml file(resx file) which can contain different kind
of resource objects(string, image, file .....). So you can add multiple
such resx files in a project. When you build the project, they will be
compiled(as embeded resource) into your assembly(or separate satellite
assemlies that contains resource for specific cultures).
For these kinds of resource, you'll use API to get resource item from
it(from assembly).
#Introduction to Resources and Localization http://msdn2.microsoft.com/en-us/lib...93(VS.71).aspx
#Resources in Applications http://msdn2.microsoft.com/en-us/lib...5x(vs.71).aspx
** For ASP.NET application, it has some further encapsulated
functionality.
You can provide a local resource file for each aspx page or serveral
global
resource files for the entire application. These resource items are easy
to reference in your aspx page(both through declarative syntax or
programatic code):
#using localization resource in ASP.NET: http://quickstarts.asp.net/QuickStar...on/localizatio
n.aspx
Sincerely,
Steven Cheng
Microsoft MSDN Online Support Lead
This posting is provided "AS IS" with no warranties, and confers no
rights.
--------------------
>>From: "TS" <ma**********@nospam.nospam> Subject: Re: Resource file vs. regular Xml file Date: Mon, 19 Nov 2007 16:42:09 -0600
steven, are resource files 1 per application or can they be split up to
have
>>many, say 1 per 10 pages of an application. IF so is there any reason to do/not do this?
thanks!!!!
"Steven Cheng[MSFT]" <st*****@online.microsoft.comwrote in message news:J2**************@TK2MSFTNGHUB02.phx.gbl.. .
>>Thanks for your followup TS,
If you're using .net resource model(resource file or embeded in
assembly),
>>then, you should not change them frequently or dynamically at runtime. Because when .net application running, the resource items will be loaded into memory after it is used, just like it load the required assemblies. Therefore, it won't let you to flexibly update and refresh it immediately if you changed them when the application is running.
BTW, if you want to implement your own resource model and component,
maybe
>>you can havea look at the following article which introducing extending the NET resource provider:
#Extending the ASP.NET 2.0 Resource-Provider Model http://msdn2.microsoft.com/en-us/library/aa905797.aspx
Sincerely,
Steven Cheng
Microsoft MSDN Online Support Lead
This posting is provided "AS IS" with no warranties, and confers no rights.
-------------------- From: "TS" <ma**********@nospam.nospam> References: <OL**************@TK2MSFTNGP03.phx.gbl> <eA**************@TK2MSFTNGP05.phx.gbl> <uU**************@TK2MSFTNGP02.phx.gbl> <ZR**************@TK2MSFTNGHUB02.phx.gbl> Subject: Re: Resource file vs. regular Xml file Date: Thu, 15 Nov 2007 08:15:57 -0600
thank you.
One concern i never asked was caching. currently i am caching my custom xml files. Do resource files get cached or need caching?
If for example my application was deployed and then we found out there
was
>>a spelling mistake, I imaging we could manually update the resource file?
In
>>>>this scenario, how does caching play in?
thanks~!
"Steven Cheng[MSFT]" <st*****@online.microsoft.comwrote in message news:ZR**************@TK2MSFTNGHUB02.phx.gbl.. . Hi TS, > I think the main advantage of using .NET resource file(or resx file) is that you can make full use of the built-in API or coding syntax
support.
>>>>For example, .NET provide "ResourceManager Class" to help you programmatically load resource keys from resource file or resx file. Also, net resource file can be embeded into assembly. If you're using custom xml solution, you'll need to define your own xml file format and use
raw
>>>>XML API to manipulate them. How do you think? > Sincerely, > Steven Cheng > Microsoft MSDN Online Support Lead > > This posting is provided "AS IS" with no warranties, and confers no rights. > > -------------------- >>From: "TS" <ma**********@nospam.nospam> >>References: <OL**************@TK2MSFTNGP03.phx.gbl> <eA**************@TK2MSFTNGP05.phx.gbl> >>Subject: Re: Resource file vs. regular Xml file >>Date: Wed, 14 Nov 2007 12:00:41 -0600 >> >>yes. >> >>do you know of the actual benefits of resource file instead of regular xml >>file? >> >>"Duy Lam" <du**********@gmail.comwrote in message >>news:eA**************@TK2MSFTNGP05.phx.gbl.. . >>TS wrote: >>>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! >>> >>I don't know what your "customer xml solution" is ? You store all >>information of controls such as text, color value (#aabbcc) in a regular >>xml file, doesn't you ? >>As far as I know, ASP.NET support resource file very well. So you either >>need a multi languages or not, you should use Resource Feature in
your
>>>>>>ASP.NET. >> >> >> >
i see that you can add resources to a resource file at runtime. My question
is, is that persisted to the file system or only in memory in which case a
server reboot would flush?
"Steven Cheng[MSFT]" <st*****@online.microsoft.comwrote in message
news:YO**************@TK2MSFTNGHUB02.phx.gbl...
Thanks for your reply TS,
For resource file, normally you will add them into project through the
following means:
** You add a resource xml file(resx file) which can contain different kind
of resource objects(string, image, file .....). So you can add multiple
such resx files in a project. When you build the project, they will be
compiled(as embeded resource) into your assembly(or separate satellite
assemlies that contains resource for specific cultures).
For these kinds of resource, you'll use API to get resource item from
it(from assembly).
#Introduction to Resources and Localization http://msdn2.microsoft.com/en-us/lib...93(VS.71).aspx
#Resources in Applications http://msdn2.microsoft.com/en-us/lib...5x(vs.71).aspx
** For ASP.NET application, it has some further encapsulated
functionality.
You can provide a local resource file for each aspx page or serveral
global
resource files for the entire application. These resource items are easy
to reference in your aspx page(both through declarative syntax or
programatic code):
#using localization resource in ASP.NET: http://quickstarts.asp.net/QuickStar...on/localizatio
n.aspx
Sincerely,
Steven Cheng
Microsoft MSDN Online Support Lead
This posting is provided "AS IS" with no warranties, and confers no
rights.
--------------------
>>From: "TS" <ma**********@nospam.nospam> Subject: Re: Resource file vs. regular Xml file Date: Mon, 19 Nov 2007 16:42:09 -0600
steven, are resource files 1 per application or can they be split up to
have
>>many, say 1 per 10 pages of an application. IF so is there any reason to do/not do this?
thanks!!!!
"Steven Cheng[MSFT]" <st*****@online.microsoft.comwrote in message news:J2**************@TK2MSFTNGHUB02.phx.gbl.. .
>>Thanks for your followup TS,
If you're using .net resource model(resource file or embeded in
assembly),
>>then, you should not change them frequently or dynamically at runtime. Because when .net application running, the resource items will be loaded into memory after it is used, just like it load the required assemblies. Therefore, it won't let you to flexibly update and refresh it immediately if you changed them when the application is running.
BTW, if you want to implement your own resource model and component,
maybe
>>you can havea look at the following article which introducing extending the NET resource provider:
#Extending the ASP.NET 2.0 Resource-Provider Model http://msdn2.microsoft.com/en-us/library/aa905797.aspx
Sincerely,
Steven Cheng
Microsoft MSDN Online Support Lead
This posting is provided "AS IS" with no warranties, and confers no rights.
-------------------- From: "TS" <ma**********@nospam.nospam> References: <OL**************@TK2MSFTNGP03.phx.gbl> <eA**************@TK2MSFTNGP05.phx.gbl> <uU**************@TK2MSFTNGP02.phx.gbl> <ZR**************@TK2MSFTNGHUB02.phx.gbl> Subject: Re: Resource file vs. regular Xml file Date: Thu, 15 Nov 2007 08:15:57 -0600
thank you.
One concern i never asked was caching. currently i am caching my custom xml files. Do resource files get cached or need caching?
If for example my application was deployed and then we found out there
was
>>a spelling mistake, I imaging we could manually update the resource file?
In
>>>>this scenario, how does caching play in?
thanks~!
"Steven Cheng[MSFT]" <st*****@online.microsoft.comwrote in message news:ZR**************@TK2MSFTNGHUB02.phx.gbl.. . Hi TS, > I think the main advantage of using .NET resource file(or resx file) is that you can make full use of the built-in API or coding syntax
support.
>>>>For example, .NET provide "ResourceManager Class" to help you programmatically load resource keys from resource file or resx file. Also, net resource file can be embeded into assembly. If you're using custom xml solution, you'll need to define your own xml file format and use
raw
>>>>XML API to manipulate them. How do you think? > Sincerely, > Steven Cheng > Microsoft MSDN Online Support Lead > > This posting is provided "AS IS" with no warranties, and confers no rights. > > -------------------- >>From: "TS" <ma**********@nospam.nospam> >>References: <OL**************@TK2MSFTNGP03.phx.gbl> <eA**************@TK2MSFTNGP05.phx.gbl> >>Subject: Re: Resource file vs. regular Xml file >>Date: Wed, 14 Nov 2007 12:00:41 -0600 >> >>yes. >> >>do you know of the actual benefits of resource file instead of regular xml >>file? >> >>"Duy Lam" <du**********@gmail.comwrote in message >>news:eA**************@TK2MSFTNGP05.phx.gbl.. . >>TS wrote: >>>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! >>> >>I don't know what your "customer xml solution" is ? You store all >>information of controls such as text, color value (#aabbcc) in a regular >>xml file, doesn't you ? >>As far as I know, ASP.NET support resource file very well. So you either >>need a multi languages or not, you should use Resource Feature in
your
>>>>>>ASP.NET. >> >> >> >
Hi TS,
For the following things you mentioned:
==========
i see that you can add resources to a resource file at runtime.
=========
do you mean use "ResourceWriter" class to programmatically add resource
into existing resource file(resx or .resource...)? If so, the modification
only reflect on the resource file on disk and won't make the runtime to
automatically reload the updated resource.
Sincerely,
Steven Cheng
Microsoft MSDN Online Support Lead
This posting is provided "AS IS" with no warranties, and confers no rights.
--------------------
>From: "TS" <ma**********@nospam.nospam> Subject: Re: Resource file vs. regular Xml file Date: Tue, 20 Nov 2007 10:24:45 -0600
>i see that you can add resources to a resource file at runtime. My
question
>is, is that persisted to the file system or only in memory in which case a server reboot would flush?
"Steven Cheng[MSFT]" <st*****@online.microsoft.comwrote in message news:YO**************@TK2MSFTNGHUB02.phx.gbl...
>Thanks for your reply TS,
For resource file, normally you will add them into project through the following means:
** You add a resource xml file(resx file) which can contain different
kind
>of resource objects(string, image, file .....). So you can add multiple such resx files in a project. When you build the project, they will be compiled(as embeded resource) into your assembly(or separate satellite assemlies that contains resource for specific cultures).
For these kinds of resource, you'll use API to get resource item from it(from assembly).
#Introduction to Resources and Localization http://msdn2.microsoft.com/en-us/lib...93(VS.71).aspx
#Resources in Applications http://msdn2.microsoft.com/en-us/lib...5x(vs.71).aspx
** For ASP.NET application, it has some further encapsulated functionality. You can provide a local resource file for each aspx page or serveral global resource files for the entire application. These resource items are easy to reference in your aspx page(both through declarative syntax or programatic code):
#using localization resource in ASP.NET: http://quickstarts.asp.net/QuickStar...on/localizatio
>n.aspx
Sincerely,
Steven Cheng
Microsoft MSDN Online Support Lead This posting is provided "AS IS" with no warranties, and confers no rights.
--------------------
>>>From: "TS" <ma**********@nospam.nospam> Subject: Re: Resource file vs. regular Xml file Date: Mon, 19 Nov 2007 16:42:09 -0600
steven, are resource files 1 per application or can they be split up to
have
>>>many, say 1 per 10 pages of an application. IF so is there any reason to do/not do this?
thanks!!!!
"Steven Cheng[MSFT]" <st*****@online.microsoft.comwrote in message news:J2**************@TK2MSFTNGHUB02.phx.gbl. .. Thanks for your followup TS,
If you're using .net resource model(resource file or embeded in
assembly),
>>>then, you should not change them frequently or dynamically at runtime. Because when .net application running, the resource items will be
loaded
>>>into memory after it is used, just like it load the required
assemblies.
>>>Therefore, it won't let you to flexibly update and refresh it immediately if you changed them when the application is running.
BTW, if you want to implement your own resource model and component,
maybe
>>>you can havea look at the following article which introducing extending the NET resource provider:
#Extending the ASP.NET 2.0 Resource-Provider Model http://msdn2.microsoft.com/en-us/library/aa905797.aspx
Sincerely,
Steven Cheng
Microsoft MSDN Online Support Lead
This posting is provided "AS IS" with no warranties, and confers no rights.
-------------------- >From: "TS" <ma**********@nospam.nospam> >References: <OL**************@TK2MSFTNGP03.phx.gbl> <eA**************@TK2MSFTNGP05.phx.gbl> <uU**************@TK2MSFTNGP02.phx.gbl> <ZR**************@TK2MSFTNGHUB02.phx.gbl> >Subject: Re: Resource file vs. regular Xml file >Date: Thu, 15 Nov 2007 08:15:57 -0600
> >thank you. > >One concern i never asked was caching. currently i am caching my custom xml >files. Do resource files get cached or need caching? > >If for example my application was deployed and then we found out there
was
>>>a >spelling mistake, I imaging we could manually update the resource file?
In
>>>>>this scenario, how does caching play in? > >thanks~! > > >"Steven Cheng[MSFT]" <st*****@online.microsoft.comwrote in message >news:ZR**************@TK2MSFTNGHUB02.phx.gbl. .. >Hi TS, >> >I think the main advantage of using .NET resource file(or resx file) >is >that you can make full use of the built-in API or coding syntax
support.
>>>>>For example, .NET provide "ResourceManager Class" to help you >programmatically load resource keys from resource file or resx file. >Also, >net resource file can be embeded into assembly. If you're using >custom >xml solution, you'll need to define your own xml file format and use
raw
>>>>>XML API to manipulate them. How do you think? >> >Sincerely, >> >Steven Cheng >> >Microsoft MSDN Online Support Lead >> >> >This posting is provided "AS IS" with no warranties, and confers no >rights. >> >> >-------------------- >>>From: "TS" <ma**********@nospam.nospam> >>>References: <OL**************@TK2MSFTNGP03.phx.gbl> ><eA**************@TK2MSFTNGP05.phx.gbl> >>>Subject: Re: Resource file vs. regular Xml file >>>Date: Wed, 14 Nov 2007 12:00:41 -0600 >>> >>>yes. >>> >>>do you know of the actual benefits of resource file instead of
regular
>>>xml >>>file? >>> >>>"Duy Lam" <du**********@gmail.comwrote in message >>>news:eA**************@TK2MSFTNGP05.phx.gbl. .. >>>TS wrote: >>>>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! >>>> >>>I don't know what your "customer xml solution" is ? You store all >>>information of controls such as text, color value (#aabbcc) in a regular >>>xml file, doesn't you ? >>>As far as I know, ASP.NET support resource file very well. So you >either >>>need a multi languages or not, you should use Resource Feature in
your
>>>>>>>ASP.NET. >>> >>> >>> >> > > >
yes you are correct, thanks!
"Steven Cheng[MSFT]" <st*****@online.microsoft.comwrote in message
news:tn***************@TK2MSFTNGHUB02.phx.gbl...
Hi TS,
For the following things you mentioned:
==========
i see that you can add resources to a resource file at runtime.
=========
do you mean use "ResourceWriter" class to programmatically add resource
into existing resource file(resx or .resource...)? If so, the modification
only reflect on the resource file on disk and won't make the runtime to
automatically reload the updated resource.
Sincerely,
Steven Cheng
Microsoft MSDN Online Support Lead
This posting is provided "AS IS" with no warranties, and confers no
rights.
--------------------
>>From: "TS" <ma**********@nospam.nospam> Subject: Re: Resource file vs. regular Xml file Date: Tue, 20 Nov 2007 10:24:45 -0600
>>i see that you can add resources to a resource file at runtime. My
question
>>is, is that persisted to the file system or only in memory in which case a server reboot would flush?
"Steven Cheng[MSFT]" <st*****@online.microsoft.comwrote in message news:YO**************@TK2MSFTNGHUB02.phx.gbl.. .
>>Thanks for your reply TS,
For resource file, normally you will add them into project through the following means:
** You add a resource xml file(resx file) which can contain different
kind
>>of resource objects(string, image, file .....). So you can add multiple such resx files in a project. When you build the project, they will be compiled(as embeded resource) into your assembly(or separate satellite assemlies that contains resource for specific cultures).
For these kinds of resource, you'll use API to get resource item from it(from assembly).
#Introduction to Resources and Localization http://msdn2.microsoft.com/en-us/lib...93(VS.71).aspx
#Resources in Applications http://msdn2.microsoft.com/en-us/lib...5x(vs.71).aspx
** For ASP.NET application, it has some further encapsulated functionality. You can provide a local resource file for each aspx page or serveral global resource files for the entire application. These resource items are easy to reference in your aspx page(both through declarative syntax or programatic code):
#using localization resource in ASP.NET: http://quickstarts.asp.net/QuickStar...on/localizatio
>>n.aspx
Sincerely,
Steven Cheng
Microsoft MSDN Online Support Lead This posting is provided "AS IS" with no warranties, and confers no rights.
-------------------- From: "TS" <ma**********@nospam.nospam> Subject: Re: Resource file vs. regular Xml file Date: Mon, 19 Nov 2007 16:42:09 -0600
steven, are resource files 1 per application or can they be split up to have many, say 1 per 10 pages of an application. IF so is there any reason to do/not do this?
thanks!!!!
"Steven Cheng[MSFT]" <st*****@online.microsoft.comwrote in message news:J2**************@TK2MSFTNGHUB02.phx.gbl.. . Thanks for your followup TS, > If you're using .net resource model(resource file or embeded in assembly), then, you should not change them frequently or dynamically at runtime. Because when .net application running, the resource items will be
loaded
>>>>into memory after it is used, just like it load the required
assemblies.
>>>>Therefore, it won't let you to flexibly update and refresh it immediately if you changed them when the application is running. > BTW, if you want to implement your own resource model and component, maybe you can havea look at the following article which introducing extending the NET resource provider: > #Extending the ASP.NET 2.0 Resource-Provider Model http://msdn2.microsoft.com/en-us/library/aa905797.aspx > Sincerely, > Steven Cheng > Microsoft MSDN Online Support Lead > > This posting is provided "AS IS" with no warranties, and confers no rights. > > -------------------- >>From: "TS" <ma**********@nospam.nospam> >>References: <OL**************@TK2MSFTNGP03.phx.gbl> <eA**************@TK2MSFTNGP05.phx.gbl> <uU**************@TK2MSFTNGP02.phx.gbl> <ZR**************@TK2MSFTNGHUB02.phx.gbl> >>Subject: Re: Resource file vs. regular Xml file >>Date: Thu, 15 Nov 2007 08:15:57 -0600 > >> >>thank you. >> >>One concern i never asked was caching. currently i am caching my >>custom xml >>files. Do resource files get cached or need caching? >> >>If for example my application was deployed and then we found out there was a >>spelling mistake, I imaging we could manually update the resource >>file? In >>this scenario, how does caching play in? >> >>thanks~! >> >> >>"Steven Cheng[MSFT]" <st*****@online.microsoft.comwrote in message >>news:ZR**************@TK2MSFTNGHUB02.phx.gbl ... >>Hi TS, >>> >>I think the main advantage of using .NET resource file(or resx file) >>is >>that you can make full use of the built-in API or coding syntax support. >>For example, .NET provide "ResourceManager Class" to help you >>programmatically load resource keys from resource file or resx file. >>Also, >>net resource file can be embeded into assembly. If you're using >>custom >>xml solution, you'll need to define your own xml file format and use raw >>XML API to manipulate them. How do you think? >>> >>Sincerely, >>> >>Steven Cheng >>> >>Microsoft MSDN Online Support Lead >>> >>> >>This posting is provided "AS IS" with no warranties, and confers no >>rights. >>> >>> >>-------------------- >>>>From: "TS" <ma**********@nospam.nospam> >>>>References: <OL**************@TK2MSFTNGP03.phx.gbl> >><eA**************@TK2MSFTNGP05.phx.gbl> >>>>Subject: Re: Resource file vs. regular Xml file >>>>Date: Wed, 14 Nov 2007 12:00:41 -0600 >>>> >>>>yes. >>>> >>>>do you know of the actual benefits of resource file instead of
regular
>>>>xml >>>>file? >>>> >>>>"Duy Lam" <du**********@gmail.comwrote in message >>>>news:eA**************@TK2MSFTNGP05.phx.gbl ... >>>>TS wrote: >>>>>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! >>>>> >>>>I don't know what your "customer xml solution" is ? You store all >>>>information of controls such as text, color value (#aabbcc) in a regular >>>>xml file, doesn't you ? >>>>As far as I know, ASP.NET support resource file very well. So you >>either >>>>need a multi languages or not, you should use Resource Feature in your >>>>ASP.NET. >>>> >>>> >>>> >>> >> >> >> >
This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: I Report, You Decide |
last post by:
A hosting service lungcapage has banned yabb, because it takes too much
CPU/memory, but phpBB is fine. Is that perl/php or the script itself? why
perl sucks more resource of a server than php? i...
|
by: Adam Parkin |
last post by:
Hello all, I am seeking some help with the following problem. I'm
working on an application where I have a resource file, and in this
resource file what I want to store is a list of file names...
|
by: Wysiwyg |
last post by:
Is there any way to add an embedded resource to a project without copying it
to the project's directory? I have shared resources and don't want each
project using the images, xml files, etc. to...
|
by: Namratha Shah \(Nasha\) |
last post by:
Hi All,
This is a resource file generation tool which converts an xml based resource formats to .net resource file i.e. (.resources) and vice-versa.
Today we will see how we will generate
...
|
by: Daniel |
last post by:
Hey guys
When you hook an event (c# 2.0 syntax): myEvent += MyMethodToFire;
You need to also unsubscribe it to avoid a resource leak so that the object
it is in gets garbage collected like so...
|
by: =?Utf-8?B?Q29saXZpZXI=?= |
last post by:
If anyone can help me with this I would really appreciate it:
I have an assembly into which I have linked a manifest file as a Win32
resource. This is necessary since I want to use a class in this...
|
by: craig |
last post by:
....quick question for anyone who might have some experience with .net
resource files in VS 2003.
I have an application that is not localized, but I would still like to be
able to place all of...
|
by: Sami Rehman |
last post by:
Hi,
I have got a C# Class library project 'MyCompany.Model.ValidationService'
that deals with
data validation. In this I have got a resource file 'RegularExpressions' to
store regular...
|
by: CSharper |
last post by:
I am using VS2008 C#3.0 and I would like to know if some one can help
me wiith the following 2 questions;
1. I have a XML file called test.xml file in resource and I would like
to how can I read...
|
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...
|
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,...
|
by: Charles Arthur |
last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
|
by: aa123db |
last post by:
Variable and constants
Use var or let for variables and const fror constants.
Var foo ='bar';
Let foo ='bar';const baz ='bar';
Functions
function $name$ ($parameters$) {
}
...
|
by: ryjfgjl |
last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
|
by: ryjfgjl |
last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
|
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
|
by: nemocccc |
last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
|
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...
| |