I am trying to cast IList type to List type but I am getting error every time.
IList
List
List<SubProduct> subProducts= Model.subproduct;
Model.subproduct returns IList<SubProduct>.
Model.subproduct
IList<SubProduct>
Try
List<SubProduct> subProducts = new List<SubProduct>(Model.subproduct);
or
List<SubProduct> subProducts = Model.subproducts as List<SubProduct>;
1.4m articles
1.4m replys
5 comments
57.0k users