internal void GetByKey(string key, ChattersDBLists.SystemInfoList systemInfoList) { OleDbCommand cmd = new OleDbCommand(); cmd.CommandText = "SELECT * FROM SystemInfo WHERE SIKey = @Key"; cmd.CommandType = CommandType.Text; cmd.Parameters.Add("@Key", OleDbType.VarChar).Value = key; DataTable dt = dataHelper.ExecuteReader(cmd); PopulateList(systemInfoList, dt); }
internal void GetAllByMenu(ChattersDBLists.MenuItemList menuItemList, int menu) { System.Data.OleDb.OleDbCommand cmd = new System.Data.OleDb.OleDbCommand(); cmd.CommandText = "SELECT * FROM MenuItem WHERE Menu = @Menu"; cmd.CommandType = System.Data.CommandType.Text; cmd.Parameters.Add("@Menu", SqlDbType.Int).Value = menu; DataTable dt = dataHelper.ExecuteReader(cmd); PopulateList(menuItemList, dt); }
internal void GetAll(string likeKey, ChattersDBLists.SystemInfoList systemInfoList) { OleDbCommand cmd = new OleDbCommand(); cmd.CommandText = "SELECT * FROM SystemInfo WHERE SIKey LIKE '%" + likeKey + "%'"; cmd.CommandType = CommandType.Text; DataTable dt = dataHelper.ExecuteReader(cmd); PopulateList(systemInfoList, dt); }