I am using the SharePoint get Lists item which returns a datatable but the type appears to be defined by the columns. E.g. I am returing 4 columns from my list so the dt variable is showing as datatable4. My variable here is dtUsersToPair
Whilst mostly this format is fine, when I am trying to delete a data row both the standard remove data row and using the remove method from the Invoke Method activities don’t work due to data type issues
The Get List Items activity for me shows that the datatype should just be DataTable. I’m not aware of any datatable datatype that cares how many columns there are, and no datatype of DataTable4 comes up in my datatype browser. I suggest just manually changing dtUsersToPair to DataTable as the Variable type (datatype).
Having tried that it didn’t work, it looks like the datatable4 pulls in the fields as part of the data structure (e.g. instead of row(0).item(“Name”), you could just reference as row(0).Name)
I’ve ended up looping the data datable4 and building a seperate data table and adding the items as arrayRows.
Feels a tad long winded but works.
That has nothing to do with it, you can reference by column name or index for any datatable.
What version of UiPath.MicrosoftOffice365.Activities are you on? Which of the Get List Items activities are you using, the “Office 365” version or the “Office 365 - Classic” version?