public ActionResult Shop(string id, string name) { DisplayStore item = new DisplayStore(); try { NameValueCollection nameValueCollection = HttpUtility.ParseQueryString(Request.Url.Query); string category = nameValueCollection["category"]; int cat = 0; if (!String.IsNullOrEmpty(category)) { cat = Convert.ToInt32(category); } StoreGateway sg = new StoreGateway(); item = sg.GetPublicStore(new Guid(id), cat); } catch (Exception exception) { ErrorDatabaseManager.AddException(exception, exception.GetType()); } return View(item); }