/// <summary> /// Sets the state of the action. /// </summary> private void SetActionState() { ImportManager importManager = GetImportManager(); Action = importManager.ActionManager.GetAction("AddTarget") as ActionAddTarget; Action.HydrateChanges(); lueCampaigns.LookupResultValue = Action.CampaignTarget.Campaign; }
/// <summary> /// Saves the state of the action. /// </summary> private void SaveActionState() { ImportManager importManager = GetImportManager(); Action = importManager.ActionManager.GetAction("AddTarget") as ActionAddTarget; Action.CampaignTarget.Campaign = (ICampaign)lueCampaigns.LookupResultValue; if (lueCampaigns.LookupResultValue != null) { if (!Action.Initialized) { Action.Initialized = true; Action.Active = true; } } else { Action.Initialized = false; Action.Active = false; } Action.SaveChanges(); Page.Session["importManager"] = importManager; }