protected void DVPersionalDetail_ItemUpdating(object sender, DetailsViewUpdateEventArgs e) { //DataRowView row = (DataRowView)((DetailsView)sender).DataItem; TextBox txtAboutMyPatner = (TextBox)((DetailsView)sender).FindControl("txtAboutMyPatner"); TextBox txtAboutMe = (TextBox)((DetailsView)sender).FindControl("txtAboutMe"); DropDownList ddlHeight = (DropDownList)((DetailsView)sender).FindControl("ddlHeight"); DropDownList ddlWeight = (DropDownList)((DetailsView)sender).FindControl("ddlWeight"); DropDownList ddlPhysicleStatus = (DropDownList)((DetailsView)sender).FindControl("ddlPhysicleStatus"); BAL.About_Me = txtAboutMe.Text.Trim(); BAL.About_My_Patner = txtAboutMyPatner.Text.Trim(); BAL.Height = ddlHeight.SelectedValue; BAL.Weight = Convert.ToInt32(ddlWeight.SelectedValue); BAL.Physical_Status = ddlPhysicleStatus.SelectedValue; BAL.Gender = Session["uid_gender"].ToString().Split('_')[1]; BAL.Id = Session["Bride_groom_Id"].ToString(); //SqlCommand com = new SqlCommand("update tblGroom set About_Me='" + txtAboutMe .Text + "' where Groom_Id=" + BAL.Id, DbManager.Con); //DbManager.Open(); //WebMsgBox.Show( com.ExecuteNonQuery().ToString()); WebMSG(DalProfile.UpdatePersionalDetail(BAL)); DVPersionalDetail.ChangeMode(DetailsViewMode.ReadOnly); LoadPersionalDetail(); // System.Threading.Thread.Sleep(3000); }
protected void DVPersionalDetail_ModeChanging(object sender, DetailsViewModeEventArgs e) { DVPersionalDetail.ChangeMode(e.NewMode); LoadPersionalDetail(); }