Print all rows of datatable in a message box

My datatable name is MarkSheet
it has columns - StudentName , Age, EmailId , Score.

The values in datatable Marksheet are the inputs from user. After taking all inputs from user I am trying to show all the rows of a datatable in a message box to user.

Text attribute of the message box -->
"The School’s marksheet provided by you is
" + MarkSheet.ToString

This is giving me the name of the datatable but i want the data.

This has been asked (and answered) several times. The general idea is to loop over each for, and then over each cell. You want to append all data to a string-typed variable, and then add a New Line character after each row. Here are just a few examples:

1 Like

@swetha_pattabhi,

currently message box doesnt support the Datatable as input.

the work arround is you can use output datatable --> which convert datatable as string format.

after you convert you can print in messagebox

Hi @swetha_pattabhi.
You may use Output Data Table activity.


Its input is a data table and its output is a string.
You may use the output from the Output Data Table activity on the message box.

Thanks and regards.
Despi

2 Likes

Thank you all. I used a string variable and have written all the Datarows to it. Finally printed the string variable in log message and message box activity

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