I have a comma string of numbers inside var named num_str
the contents of num_str look like this: "1,2,3,4,5", etc.
I'm looking for a way to add num_str to an expression to convert the number of numbers it contains into an array of integers
I want to make sure I can just refer to 'num_str' to get numbers instead of writing like {"1,2,3,4,5"}
I tried this where 'num_str' contains numbers
Dim test As String = Nothing
Dim result() As Integer = Int32.TryParse(num_str.Split(","c))
For i = 0 To result.Length - 1
test += result(i)
Next
but it does not work
what I'm looking for is a result with an array of numbers
source
share