Jnana_S_Rao
(RPA Enthusiast)
February 9, 2021, 6:44am
1
I’m reading an excel of ticket numbers, next I’m trying to convert the DT_Input variable into an integer array Int32 . However, I’m unable to complete this step. Please help!
I used the below 2 expressions which didn’t give out the expected outcome.
DT_Input.AsEnumerable().Select(Function (a)a(“Column Name”)).ToString).ToArray()
From row in DT_Input.AsEnumerable() Select Convert.ToString(row(“Column Name”)).ToArray()
@Jnana_S_Rao …please check this post …here i have made StringList…you just have to change it array and adjust it…
Jnana_S_Rao
(RPA Enthusiast)
February 9, 2021, 6:49am
3
Thanks @prasath17 I’ll take a look at this one.
Have you tested to convert the strings to integers with CInt?
DT_Input.AsEnumerable().Select(Function (a) CInt(a("Column Name").ToString.Trim)).ToArray
4 Likes
Jnana_S_Rao
(RPA Enthusiast)
February 9, 2021, 7:58am
5
Yes, it worked. Thank you so much!
2 Likes
system
(system)
Closed
February 12, 2021, 7:59am
6
This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.