C# Split String Not Working =================== Please Help. I wrote a C# program that reads code one line at a time. Each line has data seperated by tabs. Here is what my C# code is supposed to do. The line is supposed to be split into a string array by using the "Split" string methodIt is supposed to be spit read in text one line at a time and I use the "Split" method to group the line according to the tab character. But, as this screen shot shows, it does not work. Any idea why?
Could try pulling the ASCII value of each char out of the string and checking that the delimiter is a tab. As a "workaround" you could split on whatever the ASCII value of the delimiter is instead of splitting on the tab char.
I'm going to guess you need some kind of loop to deal with split method in order to enter each output to an array element.
try like this string arr[] = line.split('\\t'); http://csharp.net-informations.com/string/csharp-string-split.htm vanton.