public ActionResult MailList(int skip = 0, int take = 50, SpecialFolder specialFolder = SpecialFolder.All) { try { MailRepository mailRepository = Session["MailRepository"] as MailRepository; MailRepositoryResult <EnvelopeEmail> response = mailRepository.SearchAdvanced(skip, take, specialFolder); return(View(response.Obj)); } catch (Exception) { return(View("null")); } }