private void CreateEmptyStructureSet() { IStructureSetMutableObject ssMutable; ssMutable = _sdmxUtils.buildStructureSet(_ntdString + "SS_ID", _ntdString + "AGENCY", _ntdDSDVersion); ssMutable.AddName("en", _ntdString + "SS_NAME"); //IStructureReference dsdRef = new StructureReferenceImpl(_ntdString, // _ntdString, "1.0", // SdmxStructureType.GetFromEnum(SdmxStructureEnumType.Dsd), // new string[] { _ntdString }); //ssMutable.DataStructureRef = dsdRef; _ssMutable = ssMutable; SetSSToSession(); }
protected void Page_Load(object sender, EventArgs e) { Org.Sdmxsource.Sdmx.Api.Exception.SdmxException.SetMessageResolver(new Org.Sdmxsource.Util.ResourceBundle.MessageDecoder()); _ssMutable = null; _sdmxUtils = new SDMXUtils(); _localizedUtils = new LocalizedUtils(Utils.LocalizedCulture); _entityMapper = new EntityMapper(Utils.LocalizedLanguage); _artIdentity = Utils.GetIdentityFromRequest(Request); #region User COntrol Event Handler GetCodeListCLMSource.ucCodeListSelectedEH += new EventHandler<UserControls.GetCodeListEventArgs>(GetCodeListCLMSource_ucCodeListSelectedEH); GetCodeListCLMTarget.ucCodeListSelectedEH += new EventHandler<UserControls.GetCodeListEventArgs>(GetCodeListCLMTarget_ucCodeListSelectedEH); GetDSDSource.ucDSDSelectedEH += new EventHandler<UserControls.GetDSDEventArgs>(GetDSDSource_ucDSDSelectedEH); GetDSDTarget.ucDSDSelectedEH += new EventHandler<UserControls.GetDSDEventArgs>(GetDSDTarget_ucDSDSelectedEH); GetDataFlowSource.ucDFSelectedEH += new EventHandler<UserControls.GetDFEventArgs>(GetDataFlowSource_ucDFSelectedEH); GetDataFlowTarget.ucDFSelectedEH += new EventHandler<UserControls.GetDFEventArgs>(GetDataFlowTarget_ucDFSelectedEH); #endregion SetAction(); if (!IsPostBack) { CommonInit(); } switch (_action) { case Action.INSERT: SetInsertForm(); break; case Action.UPDATE: SetEditForm(); break; case Action.VIEW: SetViewForm(); Utils.ResetBeforeUnload(); break; } DuplicateArtefact1.ucStructureType = SdmxStructureEnumType.StructureSet; DuplicateArtefact1.ucMaintanableArtefact = _ssMutable; if (!IsPostBack) { hdnCLMSourceCodeScrollTop.Value = "0"; lbCLMSourceCode.Attributes.Add("onclick", "GetListBoxScrollPosition();"); lbCLMSourceCode.Attributes.Add("onfocus", "SetListBoxScrollPosition();"); hdnCLMTargetCodeScrollTop.Value = "0"; lbCLMTargetCode.Attributes.Add("onclick", "GetListBoxScrollPosition();"); } else { switch (hdnSelectedMappingType.Value) { case "CLM": lbCLMSourceCode.Focus(); break; case "SM": //lbSMSourceCode.Focus(); break; default: break; } } }
private void BindData() { IStructureSetObject sso = _sdmxObjects.StructureSets.FirstOrDefault(); if (sso == null) return; if (_action == Action.VIEW) { _ssMutable = sso.MutableInstance; SetSSToSession(); } SetGeneralTab(sso); SetCodeListMapTab(sso); SetStructureMapTab(sso); }
/// <summary> /// /// </summary> private void GetSSFromSession() { if (Session[_snInsSS] != null) _ssMutable = (IStructureSetMutableObject)Session[_snInsSS]; }