What is the relevance of *.resx file in Windows Forms/controls?

Manish Basantani picture Manish Basantani · Jun 8, 2010 · Viewed 7.3k times · Source

Possible Duplicate:
purpose of form1.designer.cs and form1.resx

I Understand about *.designer file grouped with a windows form/control file. But not sure what is the relevance and use of *.resx file attached.

Can i not create a form/control with this file attached to it?

Answer

Hans Passant picture Hans Passant · Jun 8, 2010

The Windows Forms designer persists designed forms by generating code. Lots of control properties are however difficult to express in code. A form's Icon property or a PictureBox' Image property for example. Lots of bytes associated with them. The .resx file format was optimized to store those property values.

A secondary use for them is to be able to easily localize your UI design. The designer makes it easy, it automatically generates .resx files for each language you support.