using System; using System.Collections.Generic; using System.Data; using Mesnac.Action.ChemicalWeighing.LjMaterial; namespace Mesnac.Action.ChemicalWeighing.LjDry { public class DrySettingDb:DBHelp { public static IList GetDry() { string sql = "select Id,Name from DrySetting "; var dt = GetTable(sql); IList ls = new List(); foreach (DataRow dr in dt.Rows) { ls.Add(new MyNameValue() { Id = Convert.ToInt32(dr[0].ToString()), Name = dr[1].ToString() }); } return ls; } } }