Consumer: Object;
The Consumer property returns the object that is a data consumer.
To work with the returned object, cast it to one of the interfaces of data consumers.
Executing the example requires a time series database with the FC_COMM identifier that contains an object of export to the text file with the EXP_OBJ identifier. Add links to the Metabase, Cubes, Dt system assemblies.
Sub UserProc;
Var
mb: IMetabase;
RubKey: Integer;
Inst: IExportRequestInstance;
Consumer: IDtTextConsumer;
Begin
mb := MetabaseClass.Active;
RubKey := mb.GetObjectKeyById("FC_COMM");
Inst := mb.ItemByIdNamespace("EXP_OBJ", RubKey).Open(Null) As IExportRequestInstance;
Consumer := Inst.Consumer As IDtTextConsumer;
Debug.WriteLine(Consumer.File);
End Sub UserProc;
After executing the example the name of the text file, used by the export object, is displayed in the console window.
See also: