Data source is an invalid type. It must be either an IListSource, IEnumerable, or IDataSource. The error is displayed when I bind the grid view
var list = d
Could the above not be shortend to..
var empInfo = dal.GetEmployeebyName(name); GridViewEmployee.DataSource = empInfo.ToList(); GridViewEmployee.DataBind();