public ActionResult Create(string idClient, HttpPostedFileBase postedFile) { try { //Create and save the new order in the table storage OrderModels order = new OrderModels(idClient, Guid.NewGuid().ToString()); order.ResourceName = postedFile.FileName; order.ModificationDate = DateTime.UtcNow; order.ResourceURL = order.saveInBlob(postedFile.InputStream, order.RowKey); order.saveEntity(); //Save as result of the operation "true" ViewBag.Process = true; // TODO: Add insert logic here return(RedirectToAction("Index", "Home", new { result = "true", idOrder = order.RowKey.ToString() })); } catch { //If the operation fail the we return and error, and the view will show an error message ViewBag.Process = false; return(RedirectToAction("Index", "Home", new { result = "false" })); } }