Exemplo n.º 1
0
        public static string GetString(StrId name,
                                       System.Globalization.CultureInfo culture = null, params string[] substitutions)
        {
            if (culture == null)
            {
                culture = System.Threading.Thread.CurrentThread.CurrentUICulture;
            }
            string format = resourceMan.GetString(name.ToString(), culture);

            if (format != null)
            {
                return(string.Format(format, substitutions));
            }
            return(name.ToString());
        }
Exemplo n.º 2
0
        ///////////////////////////////////////////////////////////////////////////////////////////////
        // Method(Public)
        ///////////////////////////////////////////////////////////////////////////////////////////////

        #region :: GetLocalizedString :: StringId로 해당 문화권의 언어를 가져옵니다.

        /// <summary>
        /// StringId로 해당 문화권의 언어를 가져옵니다.
        /// </summary>
        /// <param name="id"></param>
        /// <returns></returns>
        public string GetLocalizedString(StrId id)
        {
            //XmlDocument document = new XmlDocument();
            //document.Load(AppConfig.LOCALEXMLPATH);

            //XmlNodeList nodeList = document.SelectNodes("//Table");

            //foreach (XmlNode node in nodeList)
            //{
            //    if (Convert.ToInt32(id).ToString() != node["StringID"].InnerText)
            //        continue;

            //    return node[_culture].InnerText;
            //}

            return("");
        }