Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What is the difference between .resx and .config files in .NET?

When should I use .resx file and when go for .config file?

What is the basic difference between the both in terms of usage?

like image 641
Dhanapal Avatar asked Mar 01 '23 00:03

Dhanapal


1 Answers

If you have some text in a page that you would like to display differently for different languages, or be able to modify without recompiling your application, you can put this into a resource file.

The config file contains application configurations. The config file is a (more) secure location for holding information, and should be kept as small as possible. You will also only have one configuration file per application instance (or at least project), while you may have many resource files, for instance a web project may have a resource file per web page.

like image 137
Timbo Avatar answered Mar 03 '23 17:03

Timbo