protected void Page_Load(object sender, EventArgs e) { if (base.Request.QueryString["0001234445"] != null) { this.vid = base.Request.QueryString["0001234445"].ToString(); if (this.vid.Contains("OAI/TM/")) { this.vid = this.vid.Replace("OAI/TM/", ""); } } else { base.Response.Redirect("./appstatusc.aspx"); } //if (base.Request.QueryString["94384238"] != null) //{ // this.agt = base.Request.QueryString["94384238"].ToString(); //} //else //{ // base.Response.Redirect("./appstatusc.aspx"); //} this.pwalletID = this.t.getCheckStatusDetails2(this.vid); if (this.pwalletID != "") { this.c_mark = this.t.getMarkInfoClassByUserID(this.pwalletID); this.c_rep = this.t.getRepClassByUserID(this.pwalletID); this.c_stage = this.t.getStageClassByUserID(this.pwalletID); this.c_app = this.t.getApplicantClassByID(this.pwalletID); if ((c_app.addressID != null) && (c_app.addressID != "") && (c_app.addressID != "0")) { this.c_app_addy = this.t.getAddressClassByID(this.c_app.addressID); } if ((c_rep.addressID != null) && (c_rep.addressID != "") && (c_rep.addressID != "0")) { this.c_rep_addy = this.t.getAddressClassByID(this.c_rep.addressID); } } else { // base.Response.Redirect("./appstatusc.aspx"); } }
protected void Page_Load(object sender, EventArgs e) { if (Session["vid"] != null) { this.vid = Session["vid"].ToString(); } if (Session["amt"] != null) { this.amt = Session["amt"].ToString(); } if (Session["aid"] != null) { this.aid = Session["aid"].ToString(); } if (Session["gt"] != null) { this.gt = Session["gt"].ToString(); } this.pwalletID = this.t.getPwalletID(this.vid); if (this.pwalletID != "") { this.c_mark = this.t.getMarkInfoClassByUserID(this.pwalletID); this.c_rep = this.t.getRepClassByUserID(this.pwalletID); this.c_stage = this.t.getStageClassByUserID(this.pwalletID); this.c_app = this.t.getApplicantClassByID(this.pwalletID); this.c_app_addy = this.t.getAddressClassByID(this.c_app.addressID); Session["xserviceaddress"] = null; Session["xrepresentative"] = null; Session["xmarkinfo"] = null; Session["xapplication"] = null; Session["vid"] = null; Session["amt"] = null; Session["aid"] = null; Session["g"] = null; Session["pc"] = null; } }
protected void SaveAll_Click(object sender, EventArgs e) { string[] tx = null; TransactionOptions transactionOptions = new TransactionOptions { IsolationLevel = IsolationLevel.ReadCommitted, Timeout = new TimeSpan(0, 15, 0) }; TransactionScope scope = new TransactionScope(TransactionScopeOption.Required, transactionOptions); try { if (Session["c_pwall"] != null) { c_pwall = (tm.Stage)Session["c_pwall"]; } if (Session["c_app"] != null) { c_app = (tm.Applicant)Session["c_app"]; } if (Session["c_app_addy"] != null) { c_app_addy = (tm.Address)Session["c_app_addy"]; } if (Session["c_rep_addy"] != null) { c_rep_addy = (tm.Address)Session["c_rep_addy"]; } if (Session["c_mark"] != null) { c_mark = (tm.MarkInfo)Session["c_mark"]; } if (Session["c_aos"] != null) { c_aos = (tm.AddressService)Session["c_aos"]; } if (Session["c_rep"] != null) { c_rep = (tm.Representative)Session["c_rep"]; } tx = c_pwall.validationID.Trim().Split('-'); if (tx.Length == 3) { hwalletID = tx[2]; } else { hwalletID = "0"; } c_pwall.rtm = txt_rtm.Text; if (txt_new_date.Text != "") { c_pwall.reg_date = txt_new_date.Text; } oldname = c_app.xname; c_app.xname = xname.Text; c_app.nationality = nationality.Text; if (txt_new_date.Text != "") { c_app.reg_date = txt_new_date.Text; } c_app_addy.countryID = residence.Text; c_app_addy.stateID = xselectState.Text; c_app_addy.street = xaddress.Text; c_app_addy.telephone1 = xtelephone.Text; c_app_addy.email1 = xemail.Text; if (txt_new_date.Text != "") { c_app_addy.reg_date = txt_new_date.Text; } c_mark.tm_typeID = tmType.SelectedValue; c_mark.logo_descriptionID = logo_description.SelectedValue; oldproduct_title = c_mark.product_title; c_mark.product_title = title_of_product.Text; oldclass = c_mark.nice_class; c_mark.nice_class = national_class.SelectedValue; c_mark.nice_class_desc = nice_class_desc.Text; c_mark.national_classID = national_class.SelectedValue; c_mark.disclaimer = txt_discalimer.Text; c_mark.reg_number = TextBox1.Text; if (txt_new_date.Text != "") { c_mark.reg_date = txt_new_date.Text; } c_aos.countryID = "160"; c_aos.stateID = aos_xselectState.Text; c_aos.city = ""; c_aos.street = aos_xaddress.Text; c_aos.telephone1 = aos_xtelephone.Text; c_aos.email1 = aos_xemail.Text; if (txt_new_date.Text != "") { c_aos.reg_date = txt_new_date.Text; } c_rep.agent_code = xcode.Text; c_rep.xname = rep_xname.Text; c_rep.nationality = rep_nationality.SelectedValue; c_rep.log_staff = "0"; if (txt_new_date.Text != "") { c_rep.reg_date = txt_new_date.Text; } c_rep_addy.countryID = rep_residence.SelectedValue; c_rep_addy.stateID = xselectRepState.SelectedValue; c_rep_addy.city = ""; c_rep_addy.street = rep_address.Text; c_rep_addy.telephone1 = rep_xtelephone.Text; c_rep_addy.email1 = rep_xemail.Text; if (txt_new_date.Text != "") { c_rep_addy.reg_date = txt_new_date.Text; } if (Session["hwalletID"] != null) { hwalletID = Session["hwalletID"].ToString(); } Boolean vfile = false; if (logo_description.SelectedItem.Value != "2") { vfile = true; } else { vfile = false; } succ = t.editTrademarkTx(c_app, c_mark, c_aos, c_rep, c_app_addy, c_rep_addy, c_pwall, sl_docz, logo_pic, auth_doc, sup_doc1, sup_doc2, Server.MapPath("~/"), vfile); if (Convert.ToInt32(succ) > 0) { //ws_payx.payx ws_p = new ws_payx.payx(); //status = ws_p.UpdateHwallet(hwalletID, "Used", reg_date, title_of_product.Text); //if (status >= 0) //{ scope.Complete(); scope.Dispose(); //} //else //{ // scope.Dispose(); // succ_msg = "Record Not Edited Successfully! Please try again"; // showsearch = 0; //} } else { scope.Dispose(); succ_msg = "Record Not Edited Successfully! Please try again"; showsearch = 0; } this.adminID = this.Session["pwalletID"].ToString(); t.activity_log(this.adminID, "Edit Application", "Update", c_app.log_staff, c_pwall.data_status, title_of_product.Text, oldproduct_title, oldname, xname.Text, oldclass, national_class.SelectedValue); ///// } catch (Exception exception) { exception.ToString(); scope.Dispose(); succ_msg = "Record Not Edited Successfully! Please try again"; showsearch = 0; } finally { if (scope != null) { scope.Dispose(); } } succ_msg = "Record Edited Successfully!!!"; txt_search.Text = ""; showsearch = 0; }
protected void SearchApplicant_Click(object sender, EventArgs e) { if (txt_search.Text != "") { try { succ_msg = "0"; string c_id = t.getPwalletID(txt_search.Text); if (Convert.ToInt32(c_id) > 0) { c_pwall = t.getStageClassByUserID(c_id); if (Convert.ToInt32(c_pwall.ID) > 0) { Session["c_pwall"] = c_pwall; c_app = t.getApplicantClassByID(c_id); Session["c_app"] = c_app; c_mark = t.getMarkInfoClassByUserID(c_id); Session["c_mark"] = c_mark; c_aos = t.getAddressServiceByID(c_id); Session["c_aos"] = c_aos; c_rep = t.getRepClassByUserID(c_id); Session["c_rep"] = c_rep; if (Convert.ToInt32(c_app.ID) > 0) { c_app_addy = t.getAddressClassByID(c_app.addressID); Session["c_app_addy"] = c_app_addy; } if (Convert.ToInt32(c_rep.ID) > 0) { c_rep_addy = t.getAddressClassByID(c_rep.addressID); Session["c_rep_addy"] = c_rep_addy; } xname.Text = c_app.xname; xaddress.Text = c_app_addy.street; xtelephone.Text = c_app_addy.telephone1; xemail.Text = c_app_addy.email1; try { nationality.SelectedIndex = Convert.ToInt32(c_app.nationality) - 1; } catch (Exception ee) { } try { residence.SelectedIndex = Convert.ToInt32(c_app_addy.countryID) - 1; } catch (Exception ee) { } try { xselectState.SelectedIndex = Convert.ToInt32(c_app_addy.stateID) - 1; } catch (Exception ee) { } txt_rtm.Text = c_pwall.rtm; curtime.Value = c_pwall.reg_date; title_of_product.Text = c_mark.product_title; nice_class_desc.Text = c_mark.nice_class_desc; txt_discalimer.Text = c_mark.disclaimer; TextBox1.Text = c_mark.reg_number; tmType.SelectedIndex = Convert.ToInt32(c_mark.tm_typeID) - 1; logo_description.SelectedIndex = Convert.ToInt32(c_mark.logo_descriptionID) - 1; national_class.SelectedIndex = Convert.ToInt32(c_mark.national_classID) - 1; aos_xaddress.Text = c_aos.street; aos_xtelephone.Text = c_aos.telephone1; aos_xemail.Text = c_aos.email1; try { aos_xselectState.SelectedIndex = Convert.ToInt32(c_aos.stateID) - 1; } catch (Exception ee) { } xcode.Text = c_rep.agent_code; rep_xname.Text = c_rep.xname; rep_address.Text = c_rep_addy.street; rep_xtelephone.Text = c_rep_addy.telephone1; rep_xemail.Text = c_rep_addy.email1; try { rep_nationality.SelectedIndex = Convert.ToInt32(c_rep.nationality) - 1; } catch (Exception ee) { } try { xselectRepState.SelectedIndex = Convert.ToInt32(c_rep_addy.stateID) - 1; } catch (Exception ee) { } ///application Session["showsearch"] = 1; showsearch = 1; if (logo_description.SelectedItem.Value != "2") { logo_pic_text = "1"; } else { logo_pic_text = "0"; } } } } catch (Exception ee) { } } }
protected void Page_Load(object sender, EventArgs e) { if (logo_description.SelectedItem.Value != "2") { logo_pic_text = "1"; } else { logo_pic_text = "0"; } serverpath = base.Server.MapPath("~/"); if (this.Session["pwalletID"] != null) { if (this.Session["pwalletID"].ToString() != "") { this.adminID = this.Session["pwalletID"].ToString(); } else { base.Response.Redirect("./xcontrol.aspx"); } } else { base.Response.Redirect("./xcontrol.aspx"); } serverpath = base.Server.MapPath("~/"); xdesc_national_class = "1"; if (!IsPostBack) { Session["showsearch"] = null; } else { if ((Session["showsearch"] != null) && (Convert.ToInt32(Session["showsearch"]) > 0)) { showsearch = 1; } if (Session["c_mark"] != null) { c_mark = (tm.MarkInfo)Session["c_mark"]; } } if (logo_description.SelectedValue != "2") { logo_text = "1"; } else { logo_text = "0"; } Session["logo_description"] = logo_description.SelectedValue; if (base.IsPostBack) { national_class_desc.Text = t.getNationalClassDesc(national_class.SelectedValue); } else { } }
protected void Page_Load(object sender, EventArgs e) { //if (Session["pwalletID"] != null) //{ // if (Session["pwalletID"].ToString() != "") // { // this.admin = Session["pwalletID"].ToString(); // } // else // { // // base.Response.Redirect("./xcontrol.aspx"); // } //} //else //{ // // base.Response.Redirect("./xcontrol.aspx"); //} this.serverpath = base.Server.MapPath("~/"); if (base.Request.QueryString["0001234445"] != null) { this.vid = base.Request.QueryString["0001234445"].ToString(); if (this.vid.Contains("OAI/TM/")) { this.vid = this.vid.Replace("OAI/TM/", ""); } } else { // base.Response.Redirect("./xcontrol.aspx"); } if (base.Request.QueryString["94384238"] != null) { this.agt = base.Request.QueryString["94384238"].ToString(); } else { // base.Response.Redirect("./xcontrol.aspx"); } this.pwalletID = this.t.getCheckStatusDetails(this.vid, this.agt); if (this.pwalletID != "") { this.c_mark = this.t.getMarkInfoClassByUserID(this.pwalletID); this.c_rep = this.t.getRepClassByUserID(this.pwalletID); this.c_stage = this.t.getStageClassByUserID(this.pwalletID); this.c_app = this.t.getApplicantClassByID(this.pwalletID); if ((c_app.addressID != null) && (c_app.addressID != "") && (c_app.addressID != "0")) { this.c_app_addy = this.t.getAddressClassByID(this.c_app.addressID); } if ((c_rep.addressID != null) && (c_rep.addressID != "") && (c_rep.addressID != "0")) { this.c_rep_addy = this.t.getAddressClassByID(this.c_rep.addressID); } if (c_mark.logo_pic != "") { tm_img.ImageUrl = "../../admin/tm/" + c_mark.logo_pic; } } else { // base.Response.Redirect("./xcontrol.aspx"); } }
protected void Page_Load(object sender, EventArgs e) { this.serverpath = base.Server.MapPath("~/"); if (Session["vid"] != null) { this.vid = Session["vid"].ToString(); } if (Session["amt"] != null) { this.amt = Session["amt"].ToString(); } if (Session["aid"] != null) { this.aid = Session["aid"].ToString(); } if (Session["gt"] != null) { this.gt = Session["gt"].ToString(); } this.pwalletID = this.t.getPwalletID(this.vid); if (this.pwalletID != "") { this.c_mark = this.t.getMarkInfoClassByUserID(this.pwalletID); this.c_rep = this.t.getRepClassByUserID(this.pwalletID); this.c_stage = this.t.getStageClassByUserID(this.pwalletID); this.c_app = this.t.getApplicantClassByID(this.pwalletID); if ((c_app.addressID != null) && (c_app.addressID != "") && (c_app.addressID != "0")) { this.c_app_addy = this.t.getAddressClassByID(this.c_app.addressID); } if ((c_rep.addressID != null) && (c_rep.addressID != "") && (c_rep.addressID != "0")) { this.c_rep_addy = this.t.getAddressClassByID(this.c_rep.addressID); } if (c_mark.logo_pic != "") { tm_img.ImageUrl = "./admin/tm/" + c_mark.logo_pic; //if (File.Exists(serverpath + "\\admin\\tm\\" + c_mark.logo_pic)) //{ // tm_img.Height = new Unit(120, UnitType.Pixel); // tm_img.Width = new Unit(120, UnitType.Pixel); //try //{ // FileStream st = new FileStream(serverpath + "\\admin\\tm\\" + c_mark.logo_pic, FileMode.Open, FileAccess.Read); // System.Drawing.Image new_img = System.Drawing.Image.FromStream(st); // string ht = new_img.Height.ToString(); // string wt = new_img.Width.ToString(); // if ((ht != "") && (wt != "") && (ht != null) && (wt != null)) // { // if (Convert.ToInt32(ht) > Convert.ToInt32(wt)) // { // tm_img.Height = new Unit(320, UnitType.Pixel); // tm_img.Width = new Unit(240, UnitType.Pixel); // } // else // { // tm_img.Height = new Unit(240, UnitType.Pixel); // tm_img.Width = new Unit(320, UnitType.Pixel); // } // } // else // { // // tm_img.Height = new Unit(120, UnitType.Pixel); // // tm_img.Width = new Unit(120, UnitType.Pixel); // tm_img.Visible = false; // } //} //catch (Exception ex) //{ // tm_img.Visible = false; //} //} //else //{ // // tm_img.Height = new Unit(120, UnitType.Pixel); // // tm_img.Width = new Unit(120, UnitType.Pixel); // tm_img.Visible = false; //} } Session["xserviceaddress"] = null; Session["xrepresentative"] = null; Session["xmarkinfo"] = null; Session["xapplication"] = null; Session["vid"] = null; Session["amt"] = null; Session["aid"] = null; Session["g"] = null; Session["pc"] = null; } }
protected void SearchApplicant_Click(object sender, EventArgs e) { if (txt_search.Text != "") { try { succ_msg = "0"; string c_id = t.getPwalletID(txt_search.Text); if (Convert.ToInt32(c_id) > 0) { c_pwall = t.getStageClassByUserID(c_id); int vstatus = Convert.ToInt32(c_pwall.status); if (c_pwall.data_status == "Fresh" || c_pwall.data_status == "Valid" || c_pwall.data_status == "Re-conduct search" || c_pwall.data_status == "Search Conducted" || c_pwall.data_status == "Search 2 Conducted" || c_pwall.data_status == "Re-examine" || c_pwall.data_status == "Registrable" || vstatus <= 5 || ((c_pwall.data_status == "Kiv") && (Convert.ToInt32(c_pwall.status) == 14))) { } else { Page.ClientScript.RegisterStartupScript(this.GetType(), "showDialogue", "showDialogue('" + "Sorry You Cannot Edit Application At this Stage" + "');", true); return; } if (Convert.ToInt32(c_pwall.ID) > 0) { Session["c_pwall"] = c_pwall; c_app = t.getApplicantClassByID(c_id); Session["c_app"] = c_app; c_mark = t.getMarkInfoClassByUserID(c_id); Session["c_mark"] = c_mark; c_aos = t.getAddressServiceByID(c_id); Session["c_aos"] = c_aos; c_rep = t.getRepClassByUserID(c_id); Session["c_rep"] = c_rep; if (Convert.ToInt32(c_app.ID) > 0) { c_app_addy = t.getAddressClassByID(c_app.addressID); Session["c_app_addy"] = c_app_addy; } if (Convert.ToInt32(c_rep.ID) > 0) { c_rep_addy = t.getAddressClassByID(c_rep.addressID); Session["c_rep_addy"] = c_rep_addy; } xname.Text = c_app.xname; xaddress.Text = c_app_addy.street; xtelephone.Text = c_app_addy.telephone1; xemail.Text = c_app_addy.email1; try { nationality.SelectedIndex = Convert.ToInt32(c_app.nationality) - 1; } catch (Exception ee) { } try { residence.SelectedIndex = Convert.ToInt32(c_app_addy.countryID) - 1; } catch (Exception ee) { } try { xselectState.SelectedIndex = Convert.ToInt32(c_app_addy.stateID) - 1; } catch (Exception ee) { } txt_rtm.Text = c_pwall.rtm; curtime.Value = c_pwall.reg_date; title_of_product.Text = c_mark.product_title; nice_class_desc.Text = c_mark.nice_class_desc; txt_discalimer.Text = c_mark.disclaimer; TextBox1.Text = c_mark.reg_number; tmType.SelectedIndex = Convert.ToInt32(c_mark.tm_typeID) - 1; logo_description.SelectedIndex = Convert.ToInt32(c_mark.logo_descriptionID) - 1; national_class.SelectedIndex = Convert.ToInt32(c_mark.national_classID) - 1; aos_xaddress.Text = c_aos.street; aos_xtelephone.Text = c_aos.telephone1; aos_xemail.Text = c_aos.email1; try { aos_xselectState.SelectedIndex = Convert.ToInt32(c_aos.stateID) - 1; } catch (Exception ee) { } xcode.Text = c_rep.agent_code; rep_xname.Text = c_rep.xname; rep_address.Text = c_rep_addy.street; rep_xtelephone.Text = c_rep_addy.telephone1; rep_xemail.Text = c_rep_addy.email1; try { rep_nationality.SelectedIndex = Convert.ToInt32(c_rep.nationality) - 1; } catch (Exception ee) { } try { xselectRepState.SelectedIndex = Convert.ToInt32(c_rep_addy.stateID) - 1; } catch (Exception ee) { } ///application Session["showsearch"] = 1; showsearch = 1; if (logo_description.SelectedItem.Value != "2") { logo_pic_text = "1"; } else { logo_pic_text = "0"; } } } } catch (Exception ee) { } } }
protected void Page_Load(object sender, EventArgs e) { if (base.IsPostBack) { if (Request.Form["transID"] != null) { string transid = Convert.ToString(Request.Form["transID"]); SearchApplicant2(transid); } } else { if (Request.Form["transID"] != null) { string transid = Convert.ToString(Request.Form["transID"]); SearchApplicant2(transid); } } if (logo_description.SelectedItem.Value != "2") { logo_pic_text = "1"; } else { logo_pic_text = "0"; } serverpath = base.Server.MapPath("~/"); serverpath = base.Server.MapPath("~/"); xdesc_national_class = "1"; if (!IsPostBack) { // Session["showsearch"] = null; } else { if ((Session["showsearch"] != null) && (Convert.ToInt32(Session["showsearch"]) > 0)) { showsearch = 1; } if (Session["c_mark"] != null) { c_mark = (tm.MarkInfo)Session["c_mark"]; } } if (logo_description.SelectedValue != "2") { logo_text = "1"; } else { logo_text = "0"; } Session["logo_description"] = logo_description.SelectedValue; if (base.IsPostBack) { national_class_desc.Text = t.getNationalClassDesc(national_class.SelectedValue); } else { } }