コード例 #1
0
ファイル: Res.cs プロジェクト: frontlook-admin/FastReport
        private static string Get(string id, XmlDocument locale)
        {
            string[] categories = id.Split(new char[] { ',' });
            XmlItem  xi         = locale.Root;

            foreach (string category in categories)
            {
                int i = xi.Find(category);
                if (i == -1)
                {
                    return(null);
                }
                xi = xi[i];
            }

            return(xi.GetProp("Text"));
        }
コード例 #2
0
        private static string Get(string id, XmlDocument locale)
        {
            string[] categories = id.Split(new char[] { ',' });
            XmlItem  xi         = locale.Root;

            foreach (string category in categories)
            {
                int i = xi.Find(category);
                if (i == -1)
                {
                    return(id + " " + FBadResult);
                }
                xi = xi[i];
            }

            string result = xi.GetProp("Text");

            if (result == "")
            {
                result = id + " " + FBadResult;
            }
            return(result);
        }