2.2.4.32.10 OriginObject::FindIncomingOperations

Description

Find UIDs where this object is an output

Syntax

int FindIncomingOperations( vector<uint> & vUIDs )

Parameters

vUIDs
[output] vector to receive operation source operations UIDs

Return

the size of the vector, or -1 if error.

Examples

EX1

// Have a worksheet active which is a fit or statistical result
// of another worksheet.
// The example finds the sheets the active results worksheet depend on.
#include <Operation.h>
void OriginObject_FindIncomingOperations_Ex1()
{
    // A report sheet must be active
    Worksheet    wks = Project.ActiveLayer();
    Worksheet    wksIn;
    vector<uint> vUIDs;
    if(wks.FindIncomingOperations(vUIDs))
    {
        int nn = 1;
        for(int ii = 0; ii < vUIDs.GetSize(); ii++)
        {
            // OriginObject    oParent;
            Operation &op = (Operation &) Project.GetOperationObject(vUIDs[ii]);
            if(op)
            {
                printf("%d: %s, from %s\n", nn++, op.GetDescription(0), wks.GetName());
            }
        }
    }
}

Remark

Retrieve the UIDs of all source operations that have this object or any parts thereof (like the output DataRange intersects with a column of 'this' OriginObj which could be a column, a sheet, or a book) as output.

See Also

OriginObject::FindOutgoingOperations

Header to Include

origin.h