protected void dataSourceSubStateUserAdd_Updating(object sender, ObjectContainerDataSourceUpdatingEventArgs e) { //Update UserID e.NewValues["UserId"] = UserProfileUserId; e.NewValues["DescriptorIDList"] = GetDescriptorsSelectedByAdmin(); e.NewValues["RegionId"] = GetSelectedSubStateRegionId(); }
protected void dataSourceUserView_Updating(object sender, ObjectContainerDataSourceUpdatingEventArgs e) { UserViewData.FirstName = e.NewValues["FirstName"].ToString(); UserViewData.MiddleName = e.NewValues["MiddleName"].IsNull() ? e.NewValues["MiddleName"].ToString() : string.Empty; UserViewData.LastName = e.NewValues["LastName"].ToString(); UserViewData.NickName = e.NewValues["NickName"].IsNull() ? e.NewValues["NickName"].ToString() : string.Empty; UserViewData.PrimaryEmail = e.NewValues["PrimaryEmail"].ToString(); UserViewData.PrimaryPhone = e.NewValues["PrimaryPhone"].ToString(); }
protected void dataSourceEditSubStateRegionForReport_Updating(object sender, ObjectContainerDataSourceUpdatingEventArgs e) { DropDownList ctrlForm = (DropDownList)formViewSubStateRegionForReport.FindControl("dropDownListFormType"); DropDownList ctrlGroup = (DropDownList)formViewSubStateRegionForReport.FindControl("dropDownListGroupype"); e.NewValues["State"] = DefaultState; e.NewValues["ReprotFormType"] = (FormType)Convert.ToInt32(ctrlForm.SelectedValue); e.NewValues["Type"] = (SubStateReportType)Convert.ToInt32(ctrlGroup.SelectedValue); }
protected void dataSourceEditAgencyLocation_Updating(object sender, ObjectContainerDataSourceUpdatingEventArgs e) { e.NewValues[PrimaryPhoneKey] = e.NewValues[PrimaryPhoneKey].ToString().FormatPhoneNumber(); e.NewValues[SecondaryPhoneKey] = e.NewValues[SecondaryPhoneKey].ToString().FormatPhoneNumber(); e.NewValues[TDDKey] = e.NewValues[TDDKey].ToString().FormatPhoneNumber(); e.NewValues[TollFreeTDDKey] = e.NewValues[TollFreeTDDKey].ToString().FormatPhoneNumber(); e.NewValues[FaxKey] = e.NewValues[FaxKey].ToString().FormatPhoneNumber(); e.NewValues[PhysicalZipKey] = e.NewValues[PhysicalZipKey].ToString().FormatZip(); e.NewValues[MailingZipKey] = e.NewValues[MailingZipKey].ToString().FormatZip(); e.NewValues["Id"] = Id; }
protected void dataSourceEditSHIP_Updating(object sender, ObjectContainerDataSourceUpdatingEventArgs e) { //e.NewValues[PrimaryPhoneKey] = e.NewValues[PrimaryPhoneKey].ToString().FormatPhoneNumber(); //e.NewValues[SecondaryPhoneKey] = e.NewValues[SecondaryPhoneKey].ToString().FormatPhoneNumber(); //e.NewValues[TDDKey] = e.NewValues[TDDKey].ToString().FormatPhoneNumber(); //e.NewValues[TollFreeTDDKey] = e.NewValues[TollFreeTDDKey].ToString().FormatPhoneNumber(); //e.NewValues[FaxKey] = e.NewValues[FaxKey].ToString().FormatPhoneNumber(); //e.NewValues[PhysicalZipKey] = e.NewValues[PhysicalZipKey].ToString().FormatZip(); //e.NewValues[MailingZipKey] = e.NewValues[MailingZipKey].ToString().FormatZip(); //e.NewValues["StateValue"] = DefaultState.StateAbbr; }
protected void dataSourceEditClientContact_Updating(object sender, ObjectContainerDataSourceUpdatingEventArgs e) { int hoursSpent; int minutesSpent; var textBoxClientZIPCode = formViewEditClientContact.FindControl("textBoxClientZIPCode") as TextBox; var dropDownListCounselor = formViewEditClientContact.FindControl("dropDownListCounselor") as DropDownList; var dropDownClientCountyCode = formViewEditClientContact.FindControl("dropDownClientCountyCode") as DropDownList; var dropDownListCounselorCounty = formViewEditClientContact.FindControl("dropDownListCounselorCounty") as DropDownList; var dropDownListCounselorZipCode = formViewEditClientContact.FindControl("dropDownListCounselorZipCode") as DropDownList; e.NewValues[UserIdKey] = AccountInfo.UserId; e.NewValues[HoursSpentKey] = (int.TryParse(e.NewValues[HoursSpentKey].ToString().Replace("_", ""), out hoursSpent)) ? hoursSpent : 0; e.NewValues[MinutesSpentKey] = (int.TryParse(e.NewValues[MinutesSpentKey].ToString().Replace("_", ""), out minutesSpent)) ? minutesSpent : 0; e.NewValues["ClientPhoneNumber"] = e.NewValues["ClientPhoneNumber"].ToString().FormatPhoneNumber(); e.NewValues[ClientLearnedAboutSHIPKey] = ((e.NewValues[ClientLearnedAboutSHIPKey].ToString() == string.Empty) ? null : ((ClientLearnedAboutSHIP?)(int)e.NewValues[ClientLearnedAboutSHIPKey])); e.NewValues[ClientAgeGroupKey] = ((e.NewValues[ClientAgeGroupKey].ToString() == string.Empty) ? null : ((ClientAgeGroup?)(int)e.NewValues[ClientAgeGroupKey])); e.NewValues[ClientGenderKey] = ((e.NewValues[ClientGenderKey].ToString() == string.Empty) ? null : ((ClientGender?)(int)e.NewValues[ClientGenderKey])); e.NewValues[ClientMonthlyIncomeKey] = ((e.NewValues[ClientMonthlyIncomeKey].ToString() == string.Empty) ? null : ((ClientMonthlyIncome?)(int)e.NewValues[ClientMonthlyIncomeKey])); e.NewValues[ClientAssetsKey] = ((e.NewValues[ClientAssetsKey].ToString() == string.Empty) ? null : ((ClientAssets?)(int)e.NewValues[ClientAssetsKey])); e.NewValues[ClientMethodOfContactKey] = ((e.NewValues[ClientMethodOfContactKey].ToString() == string.Empty) ? null : ((ClientMethodOfContact?)(int)e.NewValues[ClientMethodOfContactKey])); e.NewValues[ClientFirstVsContinuingContactKey] = ((e.NewValues[ClientFirstVsContinuingContactKey].ToString() == string.Empty) ? null : ((ClientFirstVsContinuingContact?)(int)e.NewValues[ClientFirstVsContinuingContactKey])); e.NewValues[ClientPrimaryLanguageOtherThanEnglishKey] = ((e.NewValues[ClientPrimaryLanguageOtherThanEnglishKey].ToString() == string.Empty) ? null : ((ClientPrimaryLanguageOtherThanEnglish?)(int)e.NewValues[ClientPrimaryLanguageOtherThanEnglishKey])); e.NewValues[ClientReceivingSSOrMedicareDisabilityKey] = ((e.NewValues[ClientReceivingSSOrMedicareDisabilityKey].ToString() == string.Empty) ? null : ((ClientReceivingSSOrMedicareDisability?)(int)e.NewValues[ClientReceivingSSOrMedicareDisabilityKey])); e.NewValues[ClientDualEligbleKey] = ((e.NewValues[ClientDualEligbleKey].ToString() == string.Empty) ? null : ((ClientDualEligble?)(int)e.NewValues[ClientDualEligbleKey])); e.NewValues[ClientStatusKey] = ((e.NewValues[ClientStatusKey].ToString() == string.Empty) ? null : ((ClientStatus?)(int)e.NewValues[ClientStatusKey])); e.NewValues[CounselorUserIdKey] = dropDownListCounselor.SelectedValue; e.NewValues[ClientZIPCodeKey] = textBoxClientZIPCode.Text; e.NewValues[ClientCountyCodeKey] = dropDownClientCountyCode.SelectedItem.Value; e.NewValues[CounselorCountyCodeKey] = dropDownListCounselorCounty.SelectedValue; e.NewValues[CounselorZIPCodeKey] = dropDownListCounselorZipCode.SelectedItem.Text; e.NewValues[ReviewerUserIdKey] = ReviewerUserId; }
protected void dataSourceAgencyUserEdit_Updating(object sender, ObjectContainerDataSourceUpdatingEventArgs e) { //Update UserID e.NewValues["UserId"] = UserProfileUserId; e.NewValues["DescriptorIDList"] = GetDescriptorsSelectedByAdmin(); e.NewValues["RegionId"] = AgencyId; //Get the new supervisor ID DropDownList ReviewersDDL = (DropDownList)formView.FindControl("ddlReviewers"); int newReviewerId; if (int.TryParse(ReviewersDDL.SelectedValue, out newReviewerId)) { NewSupervisorId = newReviewerId; } }
protected void dataSourceUserView_Updating(object sender, ObjectContainerDataSourceUpdatingEventArgs e) { if (formView.FindControl("ddlZipcodes") != null) { DropDownList ZipcodesDDL = (DropDownList)formView.FindControl("ddlZipcodes"); if ((!string.IsNullOrEmpty(ZipcodesDDL.SelectedValue)) && (ZipcodesDDL.SelectedValue != "0")) { this.AccountInfo.CounselingLocation = ZipcodesDDL.SelectedValue; } DropDownList CountiesDDL = (DropDownList)formView.FindControl("ddlCounties"); if ((!string.IsNullOrEmpty(CountiesDDL.SelectedValue)) && (CountiesDDL.SelectedValue != "0")) { this.AccountInfo.CounselingCounty = CountiesDDL.SelectedValue; } } }
protected void dataSourceUserView_Updating(object sender, ObjectContainerDataSourceUpdatingEventArgs e) { RadioButton rb = ((RadioButton)formView.FindControl("rbActive")); IsActiveUser = rb.Checked; if (ScopeIdOfUser == Scope.State.EnumValue <int>()) { if (formView.FindControl("ddlReviewers") != null) { DropDownList ReviewersDDL = (DropDownList)formView.FindControl("ddlReviewers"); int _newReviewerId; if (int.TryParse(ReviewersDDL.SelectedValue, out _newReviewerId)) { //Need to save the new ReviewerID as Supervisor NewSupervisorId = _newReviewerId; } } } }
void TestableObjectContainerDataSource_Updating(object sender, ObjectContainerDataSourceUpdatingEventArgs e) { _UpdatingFired = true; }
protected void TrefwoordenTableDatasource_Updating(object sender, ObjectContainerDataSourceUpdatingEventArgs e) { }
protected void CategorieTableDataSource_Updating(object sender, ObjectContainerDataSourceUpdatingEventArgs e) { }
void TestableObjectContainerDataSource_Updating(object sender, ObjectContainerDataSourceUpdatingEventArgs e) { _UpdatingFired = true; }