protected void Page_Load(object sender, EventArgs e) { rsvpIdString = Request.QueryString["rsvpId"]; if (rsvpIdString != null) { rsvpIdGuid = IptechLib.Validation.GetValueGuid(rsvpIdString, true); } try { rsvp = RSVP.GetRSVP(rsvpIdGuid); } catch { } if (rsvp != null) { if (rsvp.Respond) { Response.Redirect("RSVPResponded.aspx"); } } else { Response.Redirect("RSVPResponded.aspx"); } if (!IsPostBack) { LoadForm(); PopulateForm(rsvp); } }
public RSVP SaveForm() { rsvpIdString = Request.QueryString["rsvpId"]; if (rsvpIdString != null) { rsvpIdGuid = IptechLib.Validation.GetValueGuid(rsvpIdString, true); } try { rsvp = RSVP.GetRSVP(rsvpIdGuid); } catch { } if (rsvp != null) { rsvp.IsGalaDinner = rblstGalaDinner.SelectedValue.Equals("Yes"); rsvp.Dietary = txtDietery.Text.Trim(); rsvp.WorkflowStatus = "04"; rsvp.Respond = true; rsvp.DateModifiedString = DateTime.Now.ToString(); rsvp.Save(); } return(rsvp); }
private void Page_Load(object sender, System.EventArgs e) { // check if-modified-since header to determine if we // should log again or send back a not modified result if (useCached(this.Context.Request)) { Response.StatusCode = 304; Response.SuppressContent = true; } else { // add code to log visit here // such as write to a database Response.ContentType = "image/gif"; Response.AppendHeader("Content-Length", _imgbytes.Length.ToString()); Response.Cache.SetLastModified(DateTime.Now); Response.Cache.SetCacheability(HttpCacheability.Public); Response.BinaryWrite(_imgbytes); string rsvpIdString = Request.QueryString["rsvpId"]; if (rsvpIdString != null) { RSVP rsvp = RSVP.GetRSVP(IptechLib.Validation.GetValueGuid(rsvpIdString, true)); if (rsvp != null) { rsvp.WorkflowStatus = "03"; if (rsvp.IsValid) { rsvp.Save(); } } } } }