Change access modifier of .resx to public Follow
Ahoi *,
I created a WPF application with Rider and I want to do my localization with resx. So, due to the solved issue https://youtrack.jetbrains.com/issue/RIDER-3108 it is possible to manually edit the .resx file and have the changes directly compiled to the .Designer.cs (Using a Designer like in VS would be preferred, but this is a know issue (see https://rider-support.jetbrains.com/hc/en-us/community/posts/115000356670-Designer-for-Resource-Files?input_string=Change%20access%20modifier%20of%20.resx%20to)).
BUT, what actually doesn't work, is that the resx only uses the ResXFileCodeGenerator, not the PublicResXFileCodeGenerator.
See picture:
This leads to have the access modifier of the .Designer.cs of internal, but I need public to make the localization work. How can I achieve that?
Thanks a lot for help!
Please sign in to leave a comment.
Solved it!
if anyone else runs into this problem, here is how to solve this:
- edit the .csproj file manually (context menu on project in Solution Explorer > Edit > Edit '<name>.csproj')
- search for the embedded resource tag that includes the Resources.resx file
- Change Generator child tag content to 'PublicResXFileCodeGenerator'
- save and enjoy