I am trying to use LLBL as the model as part of the MVC. My problem is in getting the data from a table called Group, and handing it off to the viewer. I get the error message:
The model item passed into the dictionary is of type 'System.Collections.Generic.List1[glossary.EntityClasses.GroupEntity]', but this dictionary requires a model item of type 'System.Collections.Generic.IEnumerable
1[glossary.CollectionClasses.GroupCollection]'.
My Code is as follows (including some commented out variations I had attempted)
private GroupCollection _gc = new GroupCollection();
//
// GET: /Home/
public ActionResult Index()
{
_gc.GetMulti(null);
//List<GroupEntity> gc =
//System.Collections.Generic.IEnumerable<GroupCollection> ii = _gc.AsEnumerable<GroupCollection>;
//List<GroupCollection> gc = _gc.AsEnumerable<GroupCollection>;
IEnumerable<GroupEntity> gList = _gc.ToList();
//IList<glossary.CollectionClasses.GroupCollection> ii = _gc.AsEnumerable<glossary.CollectionClasses.GroupCollection>;
// List<GroupEntity> ge = new List<GroupEntity>();
return View(gList);
}
any suggestions would be welcome, I am sure this is easy to do :-)