Hello,
I got a string array and values are as follows
sNames[0] = "Root | [<root>] | [ID = 1]";
sNames[1] = "Planning | [Root] | [ID = 2]";
From this I would like to just extract ID value .. 1,2..
for now am do this as :
foreach (var s in sNames)
{
int id = Convert.ToInt32(s.Split('|')[2].Split('=')[1].Substring(1,1));
...
}
Is there some other good way to do it ?
Thanks