techBeginner
techBeginner

Reputation: 3850

resource file content on localization - winforms

I have a form, two buttons and a few text boxes

when the localization is false, I can see all the properties of the form elements in InitializeComponent method of the form.

Now when I set the localization property to true, few of the properties are moved to resource file, but not all(like UseVisualStyleBackColor, ForeColor, Cursor etc are not moved to resource file).

Now my questioins are:

  1. on what basis the properties are moved to resource files (general assumption is it should either be all or none)?
  2. also why is it that the Visual Studio resource editor(one appears on double clicking the resx file) doesn't show all the properties in it(ie., AutoSize, Size, TabIndex etc are not shown but you can find them if you open the file with an xml editor)?
  3. and why some properties (which are shown in resource editor) have preceding >> characters?

Upvotes: 0

Views: 655

Answers (1)

user1486068
user1486068

Reputation: 36

  1. Basically, any property with the "LocalizableAttribute"
  2. It does show under the "Other" category. See this dropdown at the top of the editor. However, because it's the VS forms designer that looks after these particular ".resx" files (not the developer), you shouldn't normally update anything using the ".resx" editor. Leave it up to the forms designer to do this (applicable to the code-behind ".resx" file for any WinForm)
  3. These are special MSFT properties you don't need to worry about normally. There are 4 of them, i.e., Name", "Type", "Parent" and "ZOrder". Unless you're curious (I can provide details), you don't normally need to concern yourself with them.

Upvotes: 2

Related Questions