If I define a class named MyClass in xaml, I can retrieve it in code-behind by .net framework like this,
Application.Current.FindResource("keyName") as MyClass;
the “keyName” is my assignment to x:key property defined in xaml.
But in metro it doesn’t work anymore. Could someone please tell me how to do ?
Someone in msdn forum answered it. The solution was so simple that made me embarrassed.
So you can get self-defined resource in App.xaml.