DataRow is not being added to DataTable

Hello. I’m trying to use DataTable instead of Excel. I built a simple DataTable as shown in below screenshot. However, after execution is done, the row doesn’t seem to be added.

Result:

2024-03-18_154206

Hi,

How did you check it?
For now, can you try to add some activity just after AddDataRow, next set Breakpoint and run Debug mode? Workflow will stop there, then check content of the datatable at Locals panel?

image

Regards,

Hello Yoichi,

These are the results for the Add Data Row Properties

DataTable Output:

[FileName,FileID,Status
DemoString,610517562,
]

DataRow Output:

DataRow
{
HasErrors=false,
ItemArray=object[3]
{
“DemoString”,
610517562,
“”
},
RowError=“”,
RowState=Added,
Table=[TableName]
}

ArrayRow: null

This shows the DataRow is added into the DataTable correctly.
If it’s not what you want to achieve, can you elaborate?

Regards,

2024-03-18_154206

But the DataTable is empty. The values are not present in the table. Tried with ArrayRow. Same thing.

Hi,

Build DataTable doesn’t have feature to show content of current DataTable. (It’s used for creating new DataTable only )
If you need to check content, can you try to use OutputDataTable and MessageBox etc?

Regards,

Still nothing. Clearly, no row is being added.

It’s necessary to use Output-Text property of Output DataTable as the following.

Yeah I fixed that. Minor mistake.

2024-03-18_162650

1 Like

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.