コード例 #1
0
    public void loadLoanType(int id)
    {
        adminTableAdapters.LoanTypesTableAdapter loantype = new adminTableAdapters.LoanTypesTableAdapter();
        admin.LoanTypesDataTable tblLoanTypes             = loantype.GetLoanType(id);

        if (tblLoanTypes.Rows.Count > 0)
        {
            txtDescription.Value = tblLoanTypes[0].datDescription.ToString();
            this.editskip.Value  = "2";
        }
    }
コード例 #2
0
    public void loadLoanType(int id)
    {
        
        adminTableAdapters.LoanTypesTableAdapter loantype = new adminTableAdapters.LoanTypesTableAdapter();
        admin.LoanTypesDataTable tblLoanTypes = loantype.GetLoanType(id);

        if (tblLoanTypes.Rows.Count > 0)
        {
            txtDescription.Value = tblLoanTypes[0].datDescription.ToString();
            this.editskip.Value = "2";
        }
        }
コード例 #3
0
    protected void btnSave_Click(object sender, EventArgs e)
    {
        adminTableAdapters.LoanTypesTableAdapter loanTypes = new adminTableAdapters.LoanTypesTableAdapter();
        if (!(type == "update"))
        {
            loanTypes.InsertLoanTypes(txtDescription.Value.Trim());
        }
        else if (type == "update")
        {
            loanTypes.UpdateLoanType(txtDescription.Value.Trim(),
                                     id);
        }

        Page.Response.Redirect(util.RemoveQueryStringByKey(HttpContext.Current.Request.Url.AbsoluteUri, "ltedit"));
    }
コード例 #4
0
    protected void btnSave_Click(object sender, EventArgs e)
    {
        adminTableAdapters.LoanTypesTableAdapter loanTypes = new adminTableAdapters.LoanTypesTableAdapter();
        if (!(type == "update"))
        {

            loanTypes.InsertLoanTypes(txtDescription.Value.Trim());
        }
        else if (type == "update")
        {
            loanTypes.UpdateLoanType(txtDescription.Value.Trim(),
                                     id);
        }

        Page.Response.Redirect(util.RemoveQueryStringByKey(HttpContext.Current.Request.Url.AbsoluteUri, "ltedit"));
    }