C#
An object-oriented and type-safe programming language that has its roots in the C family of languages and includes support for component-oriented programming.
11,465 questions
This browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
@Jack J Jun , I am trying to extract index position and from that, extract string from list of objects but the value is returning always -1 . The purpose is to create a list of strings which will be used to create another list of strings
what my data in the list of objects is
what i am trying to achieve
]3
I think this is because you're .ToString()
on the object[]
as you're looping through a List<object[]>
. If you access the first element of the array and then .ToString()
that then it should work:
i.e. if you change this:
listnew[i].ToString()
To this:
listnew[i][0].ToString()