protected void Submit_Click(object sender, EventArgs e)
        {
            int             acc  = Convert.ToInt16(laccount.Text);
            Decimal         amm  = Convert.ToDecimal(lammount.Text);
            string          name = lname.Text;
            controllerclass con  = new controllerclass();

            con.deposite_loan(acc, amm, name);
            //int accn = Convert.ToInt16(laccount.Text);
            DataTable dt      = con.loan_ammount9(acc);
            string    ammt    = dt.Rows[0]["ammount_digit_with_interest"].ToString();
            Decimal   ammount = Convert.ToDecimal(ammt);

            if (ammount > 0)
            {
                Decimal update_ammount = ammount - amm;
                con.update_loan(acc, update_ammount);
                grid();
            }
            else
            {
                grid();
            }
            grid();
        }
        protected void Submit_Click(object sender, EventArgs e)
        {
            controllerclass con         = new controllerclass();
            Decimal         acc_no      = Convert.ToDecimal(waccc.Text);
            DataTable       dt          = con.withdraw_ammount(acc_no);
            string          ammount     = dt.Rows[0]["ammount_digit"].ToString();
            Decimal         amm_retrive = Convert.ToDecimal(ammount);
            Decimal         ammdi       = Convert.ToDecimal(ammdigit.Text);

            if (amm_retrive >= ammdi)
            {
                // controllerclass co = new controllerclass();
                Decimal acc  = Convert.ToDecimal(waccc.Text);
                string  name = wname.Text;
                Decimal ann  = Convert.ToDecimal(ammdigit.Text);


                con.withdraw(acc, name, ammdi);              //to insert withdraw ammount in withdraw table
                Decimal decrease_amm = amm_retrive - ammdi;
                con.update_deposite_cash(acc, decrease_amm); //for update in deposite table
                result.Text = "";
            }
            else
            {
                result.Text      = "YOU DONOT HAVE SUFFICINT BALANCE";
                result.ForeColor = System.Drawing.Color.Red;
            }
        }
Пример #3
0
        public void grid()
        {
            controllerclass stu = new controllerclass();
            DataTable       dt  = stu.account_manipulation();

            amgrid.DataSource = dt;
            amgrid.DataBind();
        }
        public void grid()
        {
            controllerclass stu = new controllerclass();
            DataTable       dt  = stu.loan_detail();

            loan_grid.DataSource = dt;
            loan_grid.DataBind();
        }
        public void grid()
        {
            controllerclass stu = new controllerclass();
            DataTable       dt  = stu.cusdetail();

            cusinfo.DataSource = dt;
            cusinfo.DataBind();
        }
Пример #6
0
        protected void Button2_Click1(object sender, EventArgs e)
        {
            string          srch = search.Text;
            controllerclass stu  = new controllerclass();
            DataTable       dt   = stu.search(srch);

            amgrid.DataSource = dt;
            amgrid.DataBind();
        }
Пример #7
0
        protected void Submit_Click(object sender, EventArgs e)
        {
            string          name = gusername.Text;
            string          pass = gpassword.Text;
            string          add  = address.Text;
            controllerclass con  = new controllerclass();

            con.general_signup(name, pass, add);
        }
        protected void Submit_Click(object sender, EventArgs e)
        {
            controllerclass con = new controllerclass();

            int acc = Convert.ToInt16(dacc.Text);


            Decimal amm  = Convert.ToDecimal(damm.Text);
            string  name = dname.Text;

            con.deposite(acc, amm, name);
        }
Пример #9
0
        protected void Submit_Click(object sender, EventArgs e)
        {
            Decimal         acc              = Convert.ToDecimal(laccount.Text);
            Decimal         amm              = Convert.ToDecimal(lammount.Text);
            string          name             = lname.Text;
            Decimal         rate             = Convert.ToDecimal(lrate.Text);
            Decimal         time             = Convert.ToDecimal(ltime.Text);
            controllerclass con              = new controllerclass();
            Decimal         ammount_interest = amm + ((amm * time * rate) / 100);//calculate with interest and certain ammount of time

            con.loan(acc, ammount_interest, name, rate, time);
        }
        protected void Submit_Click(object sender, EventArgs e)
        {
            controllerclass std      = new controllerclass();
            string          username = csusername.Text;
            string          pass     = cpassword.Text;
            DataTable       lbl      = std.admin_login(username, pass);

            if (lbl.Rows.Count > 0)
            {
                Response.Redirect("admin_services/account_manipulation.aspx");
            }
            else
            {
                rel.Text      = "YOU ENTER WRONG ACCOUNT NO. OR USERNAME";
                rel.ForeColor = System.Drawing.Color.Red;
            }
        }
        protected void Submit_Click(object sender, EventArgs e)
        {
            controllerclass std      = new controllerclass();
            string          username = csusername.Text;
            Decimal         acc      = Convert.ToDecimal(cl_account_no.Text);
            DataTable       lbl      = std.customer_info(acc, username);

            if (lbl.Rows.Count > 0)
            {
                Response.Redirect("~/index.aspx");
            }
            else
            {
                rel.Text      = "YOU ENTER WRONG ACCOUNT NO. OR USERNAME";
                rel.ForeColor = System.Drawing.Color.Red;
            }
        }
Пример #12
0
        protected void Button1_Click(object sender, EventArgs e)
        {
            string  username  = susername.Text;
            string  email     = semail.Text;
            int     house_no  = Convert.ToInt16(shouse.Text);
            string  vdc       = svdc.Text;
            string  district  = sdistrict.Text;
            Decimal mobile_no = Convert.ToDecimal(smobile.Text);
            string  gender;

            if (smale.Checked)
            {
                gender      = "male";
                whname.Text = "Wife name";
            }
            else
            {
                gender      = "female";
                whname.Text = "Husband Name";
            }
            string   usertype     = sdrop.SelectedItem.Text;
            string   father_name  = sfather.Text;
            string   grand_father = sgrandfather.Text;
            string   wife_name    = swifename.Text;
            DateTime date         = System.DateTime.Now;



            if (fileupload.HasFile)
            {
                // fileupload.SaveAs(Server.MapPath("~/uploads/" + fileupload.FileName));//upload file in uploads folder
                HttpPostedFile  postfile = fileupload.PostedFile;
                Stream          stream   = postfile.InputStream;
                BinaryReader    bin      = new BinaryReader(stream);
                byte[]          byt      = bin.ReadBytes((int)stream.Length);
                controllerclass con      = new controllerclass();
                con.add_account(username, email, house_no, vdc, district, mobile_no, gender, usertype, father_name, grand_father, wife_name, byt, date);
            }
            else
            {
                add_account_result.Text = "file upload first";
            }
        }
Пример #13
0
        protected void Button3_Click(object sender, EventArgs e)
        {
            controllerclass con     = new controllerclass();
            int             acc     = Convert.ToInt16(label.Text);
            DataTable       dt      = con.loan_ammount(acc);
            Decimal         a       = 0;
            string          ammount = dt.Rows[0]["ammount_digit_with_interest"].ToString();
            Decimal         amm     = Convert.ToDecimal(ammount);

            if (amm > a)

            {
                lresult.Text      = "YOU HAVE TO CLEAR LOAN FIRST";
                lresult.ForeColor = System.Drawing.Color.Red;
            }
            else
            {
                // con.loan_delete(acc);
                con.delete_account(acc);
            }
        }
Пример #14
0
        protected void Submit_Click(object sender, EventArgs e)
        {
            controllerclass con      = new controllerclass();
            string          username = gusername.Text;
            string          password = gpassword.Text;

            DataTable dt = con.general_login(username, password);

            if (dt.Rows.Count > 0)
            {
                Session["uname"] = username;


                Response.Redirect("~/indexuser.aspx");
            }
            else
            {
                result.Text      = "YOU ENTER THE WRONG UERR NAME AND PASSWORD";
                result.ForeColor = System.Drawing.Color.Red;
            }
        }
Пример #15
0
        protected void Button1_Click(object sender, EventArgs e)
        {
            Decimal acc       = Convert.ToInt16(label.Text);
            string  username  = amusername.Text;
            string  email     = amemail.Text;
            int     house_no  = Convert.ToInt16(amhouse.Text);
            string  vdc       = amvdc.Text;
            string  district  = amdistrict.Text;
            Decimal mobile_no = Convert.ToDecimal(ammobile.Text);

            string   usertype     = amdrop.SelectedItem.Text;
            string   father_name  = amfather.Text;
            string   grand_father = amgrandfather.Text;
            string   wife_name    = amwifename.Text;
            DateTime date         = System.DateTime.Now;

            controllerclass con = new controllerclass();

            con.update_account(acc, username, email, house_no, vdc, district, mobile_no, usertype, father_name, grand_father, wife_name); //);date);

            grid();
        }