Так бы и сказал, что А и Б это номера строк.
Код:
var
F : TextFile;
L : TStringList;
S : String;
C : Integer;
begin
C := 0;
L := TStringList.Create;
Try
AssignFile(F,'c:\myfile.txt');
Reset(F);
While Not EOF(F) Do
Begin
ReadLn(F,S);
Inc(C);
If (C >= A) And (C <= B)'
Then L.Add(S)
If C > B Then Break; // We don't neet to read file after B
End;
CloseFile(F);
Finally
L.Free;
End;
end;