How do I access "properties" of my .resw resource file in code?
For example, take this example RESW file (from MSDN):
I can access Farewell easily:
auto resourceLoader{ Windows::ApplicationModel::Resources::ResourceLoader::GetForCurrentView() };
const auto myString = resourceLoader.GetString(L"Farewell");
But if I try to do the same thing with Greeting.Text (which automatically sets the Text property of a control with x:Uid="Greeting", so I can't change it), my app crashes:
auto resourceLoader{ Windows::ApplicationModel::Resources::ResourceLoader::GetForCurrentView() };
const auto myString = resourceLoader.GetString(L"Greeting.Text"); // crashes
Can I access this resource in code without duplicating it?

Yes you can!
Just replace the
.s with/s:Further information
XAML calls resources that correspond to properties on a control property identifiers: whereas
Farewellcan only be loaded manually, from code,Greeting.Textcorresponds to a property on a control (and is automatically applied to any control with thex:Uid="Greeting".These property paths seem to be encoded as URIs, so you have to switch from
.to/when accessing them in code.MSDN describes that behavior on Localize strings in your UI and app package manifest#Refer to a string resource identifier from code: