コード例 #1
0
    public void loadIndustry(int id)
    {
        adminTableAdapters.GetIndustryTableAdapter industry = new adminTableAdapters.GetIndustryTableAdapter();
        admin.GetIndustryDataTable tbl = industry.GetIndustryDetails(id);

           if(tbl.Rows.Count>0)
           {
              txtDescription.Value = tbl[0].datDescription.ToString();
              this.editskip.Value  = "2";
           }
        }
コード例 #2
0
    public void loadIndustry(int id)
    {
        adminTableAdapters.GetIndustryTableAdapter industry = new adminTableAdapters.GetIndustryTableAdapter();
        admin.GetIndustryDataTable tbl = industry.GetIndustryDetails(id);

        if (tbl.Rows.Count > 0)
        {
            txtDescription.Value = tbl[0].datDescription.ToString();
            this.editskip.Value  = "2";
        }
    }
コード例 #3
0
    protected void btnSave_Click(object sender, EventArgs e)
    {
        adminTableAdapters.GetIndustryTableAdapter industry = new adminTableAdapters.GetIndustryTableAdapter();

        if (!(type == "update"))
        {
            industry.InsertIndustry(txtDescription.Value);
        }
        else if (type == "update")
        {
            industry.UpdateIndustry(txtDescription.Value.Trim(),
                                    id);
        }

        Page.Response.Redirect(util.RemoveQueryStringByKey(HttpContext.Current.Request.Url.AbsoluteUri, "idedit"));
    }
コード例 #4
0
    protected void btnSave_Click(object sender, EventArgs e)
    {
        adminTableAdapters.GetIndustryTableAdapter industry = new adminTableAdapters.GetIndustryTableAdapter();

        if (!(type == "update"))
        {

            industry.InsertIndustry(txtDescription.Value);
        }
        else if(type=="update")
        {
             industry.UpdateIndustry(txtDescription.Value.Trim(),
                                     id);
       }

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