Alternatives
Members may post updates or alternatives to this current article in order to show different
approaches or add new features.
Erm...Can you seriously not see the problem here? If not, I suspect you should go back to basics and learn to program properly instead of guessing... The following should be obvious:Your method is declared as returning a List (public List getall()) yet you are returning a string (return...
if you want to Retrun Generic List It have to be like thispublic List getall() { return db.banks.ToList(); }