DATATABLE and Invoke Workflow

Hey, community,

I noticed a strange thing when working with datatables and invoke workflows.

Suppose I have a initial_datatable, which I pass as an InArgument in an Invoke Workflow. The Invoke Workflow adds a column to the InArgument DataTable.

After executing the Invoke Workflow, the count of columns of the initial_datatable was increased by 1. As far as I knew, if the datatable was passed as an InArgument, it shouldn’t have been affected by what happens in the Invoke Workflow.

Is this how it should be?

The solution I found until now was to pass the InArgument as initial_datatable.Clone(). In this way, the initial_datatable doesn’t seem to be (3.3 KB)

Hey dear! Welcome to the UiPath Community :slightly_smiling_face:

Regarding your issue, make sure you’re enabling “Isolated” option for your input argument

Isolated - If this check box is selected, the invoked workflow runs in a separate Windows process. This helps with isolating a faulty workflow from the main workflow

More details you can find out here:

Thank you