<p>I am working on localization for a asp.net application that consists of several projects.</p>

<p>For this, there are some strings that are used in several of these projects. Naturally, I would prefer to have only one copy of the resource file in each project.</p>

<p>Since the resource files don't have an namespace (at least as far as I can tell), they can't be accessed like regular classes.</p>

<p>Is there any way to reference resx files in another project, within the same solution?</p>

[{'answer_id': 39078, 'author': 'Martin', 'author_id': 770, 'author_profile': 'https://Stackoverflow.com/users/770', 'pm_score': 2, 'selected': False, 'text': '<p>Some useful advice on how to manage a situation like this is available here:</p>\n\n<p><a href="http://www.codeproject.com/KB/dotnet/Localization.aspx" rel="nofollow noreferrer">http://www.codeproject.com/KB/dotnet/Localization.aspx</a></p>\n'}, {'answer_id': 39083, 'author': 'Jon Limjap', 'author_id': 372, 'author_profile': 'https://Stackoverflow.com/users/372', 'pm_score': 5, 'selected': True, 'text': '<p>You can just create a class library project, add a resource file there, and then refer to that assembly for common resources.</p>\n'}, {'answer_id': 39169, 'author': 'Mark Harris', 'author_id': 4026, 'author_profile': 'https://Stackoverflow.com/users/4026', 'pm_score': 3, 'selected': False, 'text': '<p>I have used this solution before to share a assembley info.cs file across all projects in a solution  I would presume the same would work fro a resource file.</p>\n\n<p>Create a linked file to each individual project/class library. There will be only one copy and every project will have a reference to the code via a linked file at compile time. Its a very elegant solution to solve shared non public resources without duplicating code.</p>\n\n<pre><code>&lt;Compile Include="path to shared file usually relative"&gt;\n  &lt;Link&gt;filename for Visual Studio To Dispaly.resx&lt;/Link&gt;\n&lt;/Compile&gt;\n</code></pre>\n\n<p>add that code to the complile item group of a csproj file then replace the paths with your actual paths to the resx files and you sould be able to open them.</p>\n\n<p>Once you have done this for one project file you should be able to employ the copy &amp; paste the linked file to other projects without having to hack the csproj.</p>\n'}]
['https://Stackoverflow.com/questions/39065', 'https://Stackoverflow.com', 'https://Stackoverflow.com/users/1090/']