hi friends i have created a code which searches for the particular word from two different files and creates a new file with the records in it but i am not able to search digits from the string the code of mine goes here:
StreamReader sr = new StreamReader(@"C:\Documents and Settings\jitendra\Desktop\RIC_SELL_080318.csv"); StreamReader sr1 = new StreamReader(@"C:\Documents and Settings\jitendra\Desktop\RIC_customer_20080318.csv");
StreamWriter sw = new StreamWriter(@"C:\strings.txt");
string strline = ""; string strline1 = "";
string[] values = null; string[] _values = null;
while (!sr.EndOfStream && !sr1.EndOfStream)
{
strline = sr.ReadLine();
strline1 = sr1.ReadLine();
values = strline.Split(',');
_values = strline1.Split(',');
if ((values.Length > 3 && values[2].StartsWith("52")) && (_values.Length > 3 && _values[2].StartsWith("52")))
{
sw.WriteLine(values[0].ToString() +"\t\t"+ strline1);
}
on increasing the string digit's of values[2].StartsWith("52") and _values[2].StartsWith("52") the file is created but it does not contain any record it is empty so can you plz help......