var Grdquery = from db in db.V_Salaries.Where(i => i.InOut_Flag == 0 && i.Year == cariyil).OrderByDescending(i => i.Id) orderby db.Worker_Name, db.Year_Name select new { db.Id, db.Year, db.Worker_Code, db.Worker_Name, db.Position_Name, db.Year_Name, db.Receipt_Date, db.SgkSalary, db.SgkAgi, db.Salary, db.Overtimes_Salary, db.Food_Price, db.Road_Price, db.Currency, db.Worker_Position, }; foreach (var row in Grdquery) { DataRow r = Table.NewRow(); r["Id"] = row.Id;//0 r["Year"] = row.Year;//1 r["Worker_Code"] = row.Worker_Code;//2 r["Worker_Name"] = row.Worker_Name;//3 r["Position_Name"] = row.Position_Name;//4 r["Year_Name"] = row.Year_Name;//5 r["Receipt_Date"] = row.Receipt_Date;//6 r["SgkSalary"] = row.SgkSalary;//7 r["SgkAgi"] = row.SgkAgi;//8 r["Salary"] = row.Salary;//9 r["Overtimes_Salary"] = row.Overtimes_Salary;//10 r["Food_Price"] = row.Food_Price;//11 r["Road_Price"] = row.Road_Price;//12 r["Currency"] = row.Currency;//13 r["Worker_Position"] = row.Worker_Position;//14 Table.Rows.Add(r); }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)