/// <summary> /// Handles the OnClick event of the cmdExternalList control. /// </summary> /// <param name="sender">The source of the event.</param> /// <param name="e">The <see cref="System.EventArgs"/> instance containing the event data.</param> protected void cmdExternalList_OnClick(object sender, EventArgs e) { ICampaign campaign = GetParentEntity() as ICampaign; if (campaign != null) { if (txtConfirmExternalList.Value.Equals("T")) { campaign.UseExternalList = true; Rules.DeleteCampaignTargets(campaign); IPanelRefreshService refresher = PageWorkItem.Services.Get <IPanelRefreshService>(); refresher.RefreshMainWorkspace(); } else //still need to post changes to 'External List' properties { campaign.UseExternalList = false; campaign.TargetAudienceList = null; campaign.TargetAudienceLocation = null; campaign.TargetAudienceTargetCount = null; campaign.Save(); } } }
/// <summary> /// Handles the OnClick event of the Save control. /// </summary> /// <param name="sender">The source of the event.</param> /// <param name="e">The <see cref="System.EventArgs"/> instance containing the event data.</param> protected void Save_OnClick(object sender, EventArgs e) { ICampaign campaign = BindingSource.Current as ICampaign; campaign.Save(); }