protected void Button1_Click(object sender, EventArgs e) { nsdoc.clsusr obj = new nsdoc.clsusr(); GridView1.DataSource = obj.srcusr(TextBox1.Text, Convert .ToInt32(Request.QueryString["gcod"])); GridView1.DataBind(); }
protected void Button1_Click(object sender, EventArgs e) { nsdoc.clsusr obj = new nsdoc.clsusr(); nsdoc.clsusrprp objprp = new nsdoc.clsusrprp(); objprp.usrnam = txtnam.Text; objprp.usreml = txteml.Text; objprp.usrpwd = txtpwd.Text; objprp.usrregdat = DateTime.Now; objprp.usrsecqst = drpqst.SelectedItem.Text; objprp.usrsecans = txtans.Text; objprp.usrsts = 'V'; try { obj.Save_Rec(objprp); /* * string bdy = "Please click the link below to verify your EmailID."; * bdy += "<br><a href=frmvrf.aspx?eml=" + txteml.Text + " >Click Here</a>"; * MailMessage mm = new MailMessage("*****@*****.**", txteml.Text, * "Confirmation Mail", bdy); * mm.IsBodyHtml = true; * SmtpClient c = new SmtpClient("mail.connectzone.in", 25); * c.Send(mm); */ Label1.Text = "Registration Successful.Verification mail has been sent on your Email ID"; txtans.Text = String.Empty; txtnam.Text = String.Empty; txteml.Text = String.Empty; } catch (Exception exp) { //Label1.Text = "Email ID already registered."; Label1.Text = exp.Message; } }
public String getnam(Int32 usrcod) { nsdoc.clsusr obj = new nsdoc.clsusr(); List <nsdoc.clsusrprp> k = obj.Find_info(usrcod); return(k[0].usrnam); }
protected void GridView1_RowEditing(object sender, GridViewEditEventArgs e) { nsdoc.clsgrpmem obj = new nsdoc.clsgrpmem(); nsdoc.clsgrpmemprp objprp = new nsdoc.clsgrpmemprp(); objprp.grpmemgrpcod = Convert.ToInt32(Request.QueryString["gcod"]); objprp.grpmemusrcod = Convert.ToInt32(GridView1.DataKeys [e.NewEditIndex][0]); objprp.grpmemjondat = DateTime.Now; obj.Save_Rec(objprp); TextBox1.Text = String.Empty; nsdoc.clsusr obj1 = new nsdoc.clsusr(); GridView1.DataSource = obj1.srcusr(TextBox1.Text, Convert .ToInt32(Request.QueryString["gcod"])); GridView1.DataBind(); DataList2.DataBind(); }
protected void Button1_Click(object sender, EventArgs e) { nsdoc.clsshr obj = new nsdoc.clsshr(); nsdoc.clsshrprp objprp = new nsdoc.clsshrprp(); objprp.shrdat = DateTime.Now; objprp.shrdoc = Convert.ToInt32(Request.QueryString["dcod"]); if (RadioButtonList1.SelectedIndex == 0) { objprp.shrgrpcod = -1; } else { objprp.shrgrpcod = Convert.ToInt32(DropDownList1. SelectedValue); } objprp.shrtyp = Convert.ToChar(RadioButtonList1.SelectedValue); objprp.shrrgt = 'R'; if (RadioButtonList1.SelectedIndex == 1) { objprp.shrusrcod = -1; } else { nsdoc.clsusr obj1 = new nsdoc.clsusr(); Int32 a = obj1.srcusrs(TextBox1.Text, Convert.ToInt32 (Request.QueryString["dcod"])); if (a == 0) { Label4.Text = "Email ID does not exist."; } else if (a == -1) { Label4.Text = "Document already shared."; } else { objprp.shrusrcod = a; } } if (Label4.Text == String.Empty) { obj.Save_Rec(objprp); } GridView1.DataBind(); }
protected void Button1_Click(object sender, EventArgs e) { nsdoc.clsusr obj = new nsdoc.clsusr(); Int32 a = obj.logincheck(TextBox1.Text, TextBox2.Text); if (a == -1) { Label1.Text = "Email Password Incorrect"; } else { FormsAuthenticationTicket tk = new FormsAuthenticationTicket( TextBox1.Text, false, 300); String s = FormsAuthentication.Encrypt(tk); HttpCookie ck = new HttpCookie(FormsAuthentication.FormsCookieName , s); Response.Cookies.Add(ck); Session["cod"] = a; Response.Redirect("user/frmprf.aspx"); } }
protected void Page_Load(object sender, EventArgs e) { if (Page.IsPostBack == false) { nsdoc.clsusr obj = new nsdoc.clsusr(); Int32 a = obj.vrfusr(Request.QueryString["eml"]); if (a == -1) { Label1.Text = "Email ID not verified"; } else { Label1.Text = "Email Verification completed."; nsdoc.clslst obj1 = new nsdoc.clslst(); nsdoc.clslstprp objprp1 = new nsdoc.clslstprp(); objprp1.lstcrtdat = DateTime.Now; objprp1.lstnam = "Root"; List <nsdoc.clsusrprp> k = obj.Find_Rec(Request.QueryString["eml"]); objprp1.lstusrcod = k[0].usrcod; obj1.Save_Rec(objprp1); } } }