public List <Glass_Lens> getGlassLens (long cat_id) { DataClasses1DataContext dc = new DataClasses1DataContext(); var q = from a in dc.GetTable<glass_len>() //orderby a.id descending select a; if (cat_id != 0) q = q.Where(a => a.cat_id.Equals(cat_id)); var result = q.Select(a => new Glass_Lens(a.id, a.piece_cost, a.piece_price, a.number, a.insert_date, a.cat_id, getGlassLensCats(a.id).First().ToString())/* Here where I want to call my function but actually this makes no sense*/) .ToList(); return result; }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)