Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- var All, f1, f2, f3: TStringList;
- i: integer;
- begin
- All := TStringList.Create;
- f1 := TStringList.Create;
- f2 := TStringList.Create;
- f3 := TStringList.Create;
- All.LoadFromFile(OpenDialog1.FileName);
- for i := 0 to All.Count - 1 do
- begin
- if CheckBox1.Checked then
- begin
- if Pos(Edit1.Text, All.Strings[i]) > 0 then f1.Add(All.Strings[i]);
- end;
- if CheckBox2.Checked then
- begin
- if Pos(Edit2.Text, All.Strings[i]) > 0 then f2.Add(All.Strings[i]);
- end;
- if CheckBox3.Checked then
- begin
- if Pos(Edit3.Text, All.Strings[i]) > 0 then f3.Add(All.Strings[i]);
- end;
- end;
- All.Free;
- if CheckBox1.Checked then
- begin
- f1.SaveToFile('Organization.txt');
- end;
- if CheckBox2.Checked then
- begin
- f2.SaveToFile('Working.txt');
- end;
- if CheckBox3.Checked then
- begin
- f3.SaveToFile('Types.txt');
- end;
- f1.Free;
- f2.Free;
- f3.Free;
- end;
Add Comment
Please, Sign In to add comment