Hello I have try to set Collection in TempData .Data is stored in TempData but I have face a issue my page is not working.
500 error display.
This is my code
private ICollection MapCategories(PagedQueryResult customEntityResult)
{
var categories = new List(customEntityResult.Items.Count());
try
{
foreach (var customEntity in customEntityResult.Items)
{
var model = (CategoryDataModel)customEntity.Model;
var category = new CategorySummary();
category.CategoryId = customEntity.CustomEntityId;
category.Title = customEntity.Title;
category.ShortDescription = model.ShortDescription;
category.UrlSlug = customEntity.UrlSlug;
Hello I have try to set Collection in TempData .Data is stored in TempData but I have face a issue my page is not working. 500 error display. This is my code private ICollection MapCategories(PagedQueryResult customEntityResult)
{
var categories = new List(customEntityResult.Items.Count());
try
{
foreach (var customEntity in customEntityResult.Items)
{
var model = (CategoryDataModel)customEntity.Model;
var category = new CategorySummary();
category.CategoryId = customEntity.CustomEntityId;
category.Title = customEntity.Title;
category.ShortDescription = model.ShortDescription;
category.UrlSlug = customEntity.UrlSlug;
Note-Without tempdata my page is working fine.