Exemplo n.º 1
0
        protected void Details_Command(object sender, CommandEventArgs e)
        {
            var employees = new NorthwindEntities().Employees;
            int employeeId = int.Parse(e.CommandArgument.ToString());

            this.FormView.DataSource = employees.Where(emp => emp.EmployeeID == employeeId).ToList();
            this.FormView.DataBind();
        }
Exemplo n.º 2
0
        public IQueryable<Employee> AllEmployees_GetData()
        {
            var employees = new NorthwindEntities().Employees;

            return employees;
        }