示例#1
0
    protected void btnSave_Click(object sender, EventArgs e)
    {
        adminTableAdapters.GetIdentificationsTableAdapter identification = new adminTableAdapters.GetIdentificationsTableAdapter();

        if (!(type == "update"))
        {
            identification.InsertIdentification(txtDescription.Value.Trim());
        }
        else if (type == "update")
        {
            identification.UpdateIdentification(txtDescription.Value.Trim(),
                                                id);
        }

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