public ActionResult Index()
        {
            try
            {
                ViewData["CityCircle"] = context.SpgetProspectingselectlist().Select(xx => new SelectListItem {
                    Value = xx.listid.ToString(), Text = xx.listname
                }).ToList();
                ViewData["Titlelist"] = context.SPgettitle().Select(xx => new SelectListItem {
                    Value = xx.ToString(), Text = xx.ToString()
                }).ToList();
                ViewData["Templatelist"] = context.SpGetEmailtemplatelist().Select(xx => new SelectListItem {
                    Value = xx.TemplateId.ToString(), Text = xx.TemplateName.ToString()
                }).ToList();

                if (TempData["Message"] != null)
                {
                    ViewBag.Message = TempData["Message"];
                }
            }
            catch (Exception ex)
            {
                cm.ErrorExceptionLogingByService(ex.ToString(), "EmailSendFrom" + ":" + new StackTrace().GetFrame(0).GetMethod().Name, "Index", "NA", "NA", "NA", "WEB");
            }

            return(View());
        }
        public ActionResult Index()
        {
            var emaillist = new List <SpGetEmailtemplatelist_Result>();

            try
            {
                emaillist = context.SpGetEmailtemplatelist().ToList();
            }
            catch (Exception ex)
            {
                cm.ErrorExceptionLogingByService(ex.ToString(), "EmailTemplate" + ":" + new StackTrace().GetFrame(0).GetMethod().Name, "Index", "NA", "NA", "NA", "WEB");
            }

            return(View(emaillist));
        }