public ProductMenager(string title, int pack, int allblok) { work = new WorkFile(); NamberPage = 1; Title = title; Pack = pack; NumberPack = 1; AllBlok = allblok; }
private string[] SearchF(Regex filtreT, ParserSettings Settings, bool line) { string[] massrez = new string[Settings.CountLine + 1]; WorkFile workFile = new WorkFile(); int fulllines = System.IO.File.ReadAllLines(Settings.PathRez).Length; workFile.OpenFilePathReader(Settings.PathRez); int flagtitle = Settings.CountLine + 1; string title = ""; while (true) { string temp = workFile.ReadLine(); if (temp == null) { break; } if (flagtitle == Settings.CountLine + 1) { title = temp; flagtitle = 0; } MatchCollection matches = filtreT.Matches(temp); if (matches.Count > 0) { if (line == false) { massrez[0] = temp; flagtitle = Settings.CountLine; for (int j = 1; j < Settings.CountLine + 1; j++) { massrez[j] = workFile.ReadLine(); } } else { massrez[0] = title; massrez[1] = temp; } for (int i = 0; i < massrez.Length; i++) { SearchResultsL.Items.Add(massrez[i]); } } else { flagtitle++; } } workFile.CloseFileR(); return(massrez); }
public ProductMenager() { work = new WorkFile(); }