예제 #1
0
    protected void lnk_ForgetPassword_Click(object sender, EventArgs e)
    {
        String    sql, cnt, Msg;
        DataTable dr;

        sql = " SELECT * FROM tbl_Member WHERE EmailId='" + txt_MailForgetPass.Text + "'";
        dr  = c1.SelectDT(sql);
        if (dr.Rows.Count == 0)
        {
            lbl_Msg.Text = "This EmailId is Not Registered.";
        }
        else
        {
            Msg = "Your Password is " + dr.Rows[0]["Password"].ToString();

            c1.SendMailHTMLGmail(txt_MailForgetPass.Text, "Your Password ", Msg);
            lbl_Msg.Text = "Your Password is sent";
        }
    }