Localizable string only shows some [solved]
Hi
I have the problem that only some strings are shown so that they can be moved to resources.
For example:
var items = new List<ItemInfo> { new ItemInfo {ID = 1, ParentID = 0, Name = Resources.MainWin_worker_test_DoWork_Testing}, new ItemInfo {ID = 2, ParentID = 1, Name = "Programming"}, new ItemInfo {ID = 3, ParentID = 1, Name = Resources.MainWin_worker_test_DoWork_Testing}, new ItemInfo {ID = 4, ParentID = 1, Name = "Writing Log"}, };
The 2 remaining strings are not shown in code issues.
Please sign in to leave a comment.
Hello Kardo,
Could you please attach a sample solution which will demonstrate the problem? Also please specify the version of installed ReSharper.
Thanks!
Hi
Resharper version Build 8.2.1000.4556 on 2014-05-19T09:12:38
Plugins: 1
#1. “NuGet support for ReSharper” v1.3.0.16602 by JetBrains
Visual Studio 12.0.30501.0.
I think I figured out why only some strings were changed.
In another part (another method in the class) I had '
This seems to be the reason I managed to change some strings to resources in ItemInfo.
I'll attach a solution about the part that resharper won't change unless there is the same string somewhere else (as setting a lable or similar). Is there a reason resharper won't change this sort of strings?
Attachment(s):
WindowsFormsApplication1.rar.zip
How is your setting of "Localizable Inspector" in the project properties? I had to change it from "Optimistic" to "Pessimistic" to get all strings moved to resources.
Regards
Klaus
Hello Kardo,
Thanks for the solution.
If you are talking about 'this.Text = "Form1;"' string in Form1.Designer.cs file - ReSharper does not highlight anything in generated code. To get it there, please do the folowing: ReSharper | Options | Code Inspection | Generated Code
Also check that needed project in its Property Window (F4 shortcut) has the following settings adjusted:
Thanks!
Attachment(s):
2014-06-06_1438.png
Thanks
This helped