Ejemplo n.º 1
0
        static public string InquireLocalizedWord(string inquireKey)
        {
            ResourceDictionary dict = new ResourceDictionary();

            if (SupportedLanguage.ContainsKey(PreferenceLanguage))
            {
                dict.Source = new Uri(@"Resources\Language\" + PreferenceLanguage + ".xaml", UriKind.Relative);
            }
            else
            {
                dict.Source = new Uri(@"Resources\Language\en-US.xaml", UriKind.Relative);
            }

            if (dict.Contains(inquireKey))
            {
                return(dict[inquireKey].ToString());
            }
            else
            {
                return(null);
            }
        }