J
Justin Rich
using .net 2.0.50110
String line;
RegexOptions options = ((RegexOptions.IgnorePatternWhitespace |
RegexOptions.Singleline)| RegexOptions.IgnoreCase);
Regex headerRE = new
Regex(@"\\d{5,5}(?<an8>\\d{5,5})\\s(?<bu>\\d{2,2}).(?<mcu>\\d{3,3})",options);
Match headerM = headerRE.Match(line);
while(headerM.Success)
......
line = aaa,bbbbb 0001047611 19-372 MFG10
it should match and pull the middle numbers...
i ran it in The Regulator and its ok and i ran it at
http://www.regexlib.com/RETester.aspx and the regular expression is ok.
i step through the code and the line is ok.. so i have no idea why
headerM.Success is always false!
also line comes from a file read from StreamReader.ReadLine
Thanks
Justin
String line;
RegexOptions options = ((RegexOptions.IgnorePatternWhitespace |
RegexOptions.Singleline)| RegexOptions.IgnoreCase);
Regex headerRE = new
Regex(@"\\d{5,5}(?<an8>\\d{5,5})\\s(?<bu>\\d{2,2}).(?<mcu>\\d{3,3})",options);
Match headerM = headerRE.Match(line);
while(headerM.Success)
......
line = aaa,bbbbb 0001047611 19-372 MFG10
it should match and pull the middle numbers...
i ran it in The Regulator and its ok and i ran it at
http://www.regexlib.com/RETester.aspx and the regular expression is ok.
i step through the code and the line is ok.. so i have no idea why
headerM.Success is always false!
also line comes from a file read from StreamReader.ReadLine
Thanks
Justin