IPrxSlice.GetRecentChanges

Syntax

GetRecentChanges: IMatrix;

Description

The GetRecentChanges method returns a matrix of changed values of regular report slice.

Comments

Each time the regular report data is edited the method returns a new matrix that contains the current changes for the slice.

After report or area data is saved the method returns an empty matrix.

Example

Executing the example requires a form, a button with the Button1 identifier on this form, the ReportBox component, and the UiReport component named UiReport1, that is used as a data source for ReportBox, and a regular report with the Rep_1 identifier. The assembly inspector must contain links to the following system assemblies: Report, Metabase, Forms, Matrix.

The example is a handler of the OnClick event for a button.

Sub OBJ46841FormOnShow(Sender: Object; Args: IEventArgs);
Begin
    mb:= MetabaseClass.Active;
    report:= mb.ItemById("Rep_1").Open(NullAs Iprxreport;
    UiReport1.Instance:= report;
End Sub OBJ46841FormOnShow;

Sub Button1OnClick(Sender: Object; Args: IMouseEventArgs);
Var
    m_s :IMatrix;
    Iter: IMatrixIterator;
Begin
    m_s:= report.DataSources.Item(0).Slices.Item(0).GetRecentChanges;
    Iter := m_s.CreateIterator;
    Iter.Move(IteratorDirection.First);
    While Iter.Valid Do
        Debug.Write(Iter.Value + " ");
        Iter.Move(IteratorDirection.Next);
    End While;
End Sub Button1OnClick;

After executing the example on editing the data and clicking the button the changed values are displayed in the console.

See also:

IPrxSlice