Carlo
Carlo

Reputation: 25959

Using one Resources.resw file for two or more projects in the same solution

So as the title states it, I'm trying to use one Resource.resw file to get string for two projects that exist in the same solution. On the code behind I can use the resource manager correctly, but on XAML, using the x:uid to automatically get the resource (like it's explain in this example) does not work from the project that doesn't have the Resources.resw file.

Is there any setting I'm missing so XAML can find the Resources.resw automatically. Of course the reason I'm trying to do this is to avoid redundancy - we definitely don't want two Resources files that contain the same strings.

Thanks in advance.

Upvotes: 1

Views: 1096

Answers (1)

Carlo
Carlo

Reputation: 25959

Someone from our team found the solution, basically we have to state the path to the Resource file in the x:Uid property:

<TextBlock x:Uid="/Errors/AlreadyRegistered"></TextBlock>

It's explained in Microsoft's documentation.

Upvotes: 1

Related Questions