public List <ListItem> GetListItems(string category, string title)
        {
            try
            {
                var list = new List <ListItem>();
                if (!string.IsNullOrEmpty(title))
                {
                    var items = SAP_Vendor_Items.Where(d => d.Category == category && d.Enable == "1" && d.Value.ToLower().Trim().Contains(title.ToLower().Trim())).Take(500).Select(d => new { d.Value, d.Description }).OrderBy(d => d).ToList();
                    foreach (var item in items)
                    {
                        list.Add(new ListItem(item.Description, item.Value));
                    }
                }
                else
                {
                    var items = SAP_Vendor_Items.Where(d => d.Category == category && d.Enable == "1").Take(500).Select(d => new { d.Value, d.Description }).OrderBy(d => d).ToList();

                    foreach (var item in items)
                    {
                        list.Add(new ListItem(item.Description, item.Value));
                    }
                }
                return(list);
            }
            catch (Exception ex)
            {
                throw ex;
            }
        }
 public void BindListItems(ListControl list, string category)
 {
     try
     {
         list.Items.Clear();
         list.Items.Insert(0, new ListItem("", ""));
         var items = SAP_Vendor_Items.Where(d => d.Category == category && d.Enable == "1").Select(d => new { d.Value, d.Description }).OrderBy(d => d).ToList();
         foreach (var item in items)
         {
             list.Items.Add(new ListItem(item.Description, item.Value));
         }
     }
     catch (Exception ex)
     {
         throw ex;
     }
 }
 public List <string> GetListItemTitles(string category)
 {
     return(SAP_Vendor_Items.Where(d => d.Category == category && d.Enable == "1").Select(d => d.Value).OrderBy(d => d).ToList());
 }
 public List <SAP_Vendor_Items> GetTQListItems(string category)
 {
     return(SAP_Vendor_Items.Where(d => d.Category == category).OrderBy(d => d.Value).ToList());
 }