How to update specific row in data table



Hi guys,
I have a table with phone numbers as phone_table={911111111111,2222222222,913333333333,914444444444,5555555555}. now i have to add 91 before the 10 digit phone numbers… and i have to update the phone_table. The output should be like phone_table = {911111111111, 912222222222, 913333333333, 914444444444, 915555555555}.

Please guys help me if you know

Changing a row of a datatable iwth a given condition

Hi @Sunitha_Bist,

You need to loop through entire datatable using “For each row” activity and then in the sequence you need use assign as :

row(0).ToString = “91” + row(0).ToString
row(1).ToString = “91” + row(1).ToString
row(2).ToString = “91” + row(2).ToString
row(n).ToString = “91” + row(n).ToString

for all the columns.



hi vikas.Jain
Thanks for your reply,
I dont need for all the rows because some will have by default as 91… So i gave If condition over there as if(row(0).ToString=10) then row(0).ToString = “91” + row(0).ToString… my question is that, how can i update in phone_table and it is not in column… it is in row wise in table


@Sunitha_Bist, A table will surely have column and rows.

However with the example you have given, You can split the elements on the basis of “,” into an array/list, then append it with 91 and finally, assign it back to the same array or list.



thank you vikas.jain… it worked for me


Here Take that all data into DataTable…Run a “For each Loop” for the data table and check
//Leave it




Try with this it will work…