SetMembersRecord(Value: IOrmRecord);
Value. Record from that attributes values are set.
The SetMembersRecord method sets attributes values from a record.
Executing the example requires a form containing the Button component with the Button identifier and the MetaAttributesTreeList component with the MetaAttributesTreeList1 identifier. The MetaAttributesBreadcrumb component with the MetaAttributesBreadcrumb1 identifier must be connected to this component. MetaAttributesBreadcrumb1 must be set up to work with the time series database that contains a time series with the 155813 key. The example is a handler of the OnClick event for the Button1 component. Before executing the example, select one factor in the MetaAttributesTreeList1 component.
Add links to the Metabase, Cubes, Orm and Rds system assemblies.
Sub Button1OnClick(Sender: Object; Args: IMouseEventArgs);
Var
mb: IMetabase;
RubrIn: IRubricatorInstance;
RubRev: IRubricatorRevision;
FactD: IRubricatorFactData;
MemberRecord: IMetaDataMemberRecord;
memb: IMetaMember;
Record: IOrmRecord;
Begin
mb := MetabaseClass.Active;
RubrIn := MetaAttributesBreadcrumb1.Rubricator;
RubRev := RubrIn.OpenRevision("Test_Revision");
FactD := RubrIn.GetFactData(155813, DictionaryGetDataOptions.EditExisting);
MemberRecord := FactD.Record;
Memb := MetaAttributesTreeList1.SelectedMembers.Current;
Record := memb.Tuple;
MemberRecord.SetMembersRecord(Record);
FactD.SaveAndRevise(SaveRubricatorDataOptions.NoValidateRules);
End Sub Button1OnClick;
After executing the example attribute values of a selected factor are set for the factor with the specified key.
See also: