Reading data from data table array

Hi

I am extracting a table from mail body using activity “Extract data tables from HTML” and store in a variable as data table array then reading the each item but for each activity is not reading the multiple rows.

When I debug into this and found the data in string format.

Can some one please me on this issue how I can read the each row?

1 Like

Hey @Naresh_Upadhyay,

Kindly post any screenshots or give further details.

Even the xaml and mail file may provide an easy way to debug.

Thanks :slight_smile:

Assuming i understand you correctly, A for each is supposed to give you each item from the array, not the entire row

if you know the column names or at least indexes you can use that to get the entire array. eg

item(0).ToString + item(1).ToString etc.

Hi SenzoD

Thanks for your reply!! Here is the activity and data which I am getting after storing it to table.

Data :-
[PO Line Number,Error Msg,Failed Product,Correct EDP,Item Desc
10,Product not found for item number(edp):123 SUBST.,123 SUBST,00162805,Test Material VAR Order Processing
20,Product not found for item number(edp):9100005577.,9100005577,00162678,STEREO HEADSET H151
]

I could see this data while debugging into this. From the above data, I am able to get 123 SUBST,00162805 from first row but not getting the data from send row e.g. 9100005577,00162678.
Tried your given solution but it giving me only data from 1st row. Request you to please help.
Thanks

please use Output datatable activity, and message box to print the entire datatable as a string, i just want to see what your data looks like

I am getting compiler error while using “output dataTable” activity.

Please check the type for dt_mail_t. It looks like it is a one dimensional array of the datatable .

@Naresh_Upadhyay,

Use a for each activity and the output datable activity should be inside the for each since its an array of DT

used the output dataTable activity inside the for each loop then got the data as mention in inserted screen.

image

1 Like

I was able to fix the issue for now after saving the array into excel file and then store into data table.

Hi Naresh,

I am trying to do something similar. Can you share details or your xamil file. When i am using for each its not moving to the body section.

image