コード例 #1
0
    protected void DVEducation_ItemUpdating(object sender, DetailsViewUpdateEventArgs e)
    {
        DataRowView  row           = (DataRowView)((DetailsView)sender).DataItem;
        DropDownList ddlProfession = (DropDownList)((DetailsView)sender).FindControl("ddlProfession");
        DropDownList ddlIncome     = (DropDownList)((DetailsView)sender).FindControl("ddlIncome");
        DropDownList ddlEducation  = (DropDownList)((DetailsView)sender).FindControl("ddlEducation");
        TextBox      txtoccupation = (TextBox)((DetailsView)sender).FindControl("txtoccupation");

        BAL.Profession_Id = ddlProfession.SelectedValue;
        BAL.Anual_Incom   = ddlIncome.SelectedValue;
        BAL.Education     = ddlEducation.SelectedValue;
        BAL.Occupation    = txtoccupation.Text.Trim();
        BAL.Gender        = Session["uid_gender"].ToString().Split('_')[1];
        BAL.Id            = Session["Bride_groom_Id"].ToString();

        WebMSG(DalProfile.UpdateEducationlDetail(BAL));
        DVEducation.ChangeMode(DetailsViewMode.ReadOnly);
        LoadEducation();
    }
コード例 #2
0
 private void LoadEducation()
 {
     DVEducation.DataSource = BAL.SelectEducationDetails();
     DVEducation.DataBind();
 }
コード例 #3
0
 protected void DVEducation_ModeChanging(object sender, DetailsViewModeEventArgs e)
 {
     DVEducation.ChangeMode(e.NewMode);
     LoadEducation();
 }