public static void InitSelectorInfo() { XDocument xml = XDocument.Load("/SMT.FB.UI;component/Common/UIXml/UIConfig.xml"); List <SelectorInfo> listResult = new List <SelectorInfo>(); var selectors = from p in xml.Element("FB").Element("Selectors").Elements("Selector") select p; foreach (XElement se in selectors) { SelectorInfo selectorInfo = new SelectorInfo(); SetValue(selectorInfo, se); selectorInfo.Items = GetGridItem(se); listResult.Add(selectorInfo); } Selects = listResult; }
public static void InitSelectorInfo() { XDocument xml = XDocument.Load("/SMT.FB.UI;component/Common/UIXml/UIConfig.xml"); List<SelectorInfo> listResult = new List<SelectorInfo>(); var selectors = from p in xml.Element("FB").Element("Selectors").Elements("Selector") select p; foreach (XElement se in selectors) { SelectorInfo selectorInfo = new SelectorInfo(); SetValue(selectorInfo, se); selectorInfo.Items = GetGridItem(se); listResult.Add(selectorInfo); } Selects = listResult; }