Gaurav07
(Gaurav Bahuguna)
1
I have a excel file with column with name - Ship name
I read this excel using read range and output data table is DT
now I have a string like - name = “MT”
am getting error when I am writing this value inside escel using assign like this
DT(“Ship name”) = name.tostring
1 Like
TimK
(Tim Kok)
2
You have to specify which row you want to update.
it will be DT.Rows(X).Item(“Ship name”) = name.tostring
X is the row index you wish to update in the datatable.
1 Like
Hi @Gaurav07
Tried to iterate in the loop and make the changes in the dataable.
something like that to update the datatable.
Also you can follow what @TimK shared .
cheers
Happy learning
2 Likes
Gaurav07
(Gaurav Bahuguna)
4
Thanks and in the end I have to use write range to write the assigned values to the excel file
1 Like
Gaurav07
(Gaurav Bahuguna)
5
I am getting this error
RunData.rows(Runcount).item(0) = ShipName.ToString
1 Like
TimK
(Tim Kok)
6
What are you assigning Runcount as? it should start from 0 index.