public void LinkButton_Command(object sender, CommandEventArgs e) { CatalogAction action = new CatalogAction(Context); action.ShowProductsByCategory(e.CommandArgument.ToString()); this.CurrentController.NextView = action.NextViewToDisplay; }
private void Page_Load(object sender, System.EventArgs e) { if (IsPostBack && (Request.Form["__EVENTTARGET"] == "BODY_CONTROL")) { CatalogAction action = new CatalogAction(this.Context); try { action.ShowProductsByCategory(Request.Form["__EVENTARGUMENT"]); this.CurrentController.NextView = action.NextViewToDisplay; } catch { this.CurrentController.NextView = WebViews.ERROR; } } }