private void SaveToXmlFile() { string appPath = Application.StartupPath; string xmlPath = appPath + @"\parameter\"; if (!Directory.Exists(xmlPath)) { Directory.CreateDirectory(xmlPath); } HotchPotchV1d0.SaveToXmFile <DiningTableInfoSetV1d0>(DiningTableInfoSet, xmlPath + "DiningTableInfoSet.xml"); }
/// <summary> /// 装载数据 /// </summary> private void LoadData() { try { string currDir = System.IO.Directory.GetCurrentDirectory(); string filename = currDir + @"\parameter\DiningTableInfoSet.xml"; DiningTableInfoSet = HotchPotchV1d0.ReadFromXmlFile <DiningTableInfoSetV1d0>(filename); } catch (Exception ex) { SimpleLoger.Instance.Error(ex); } }