我尝试在我的Delphi 2007程序中使用这段代码
function ExtractText(const Str: string; const Delim1, Delim2: string): string;
var
pos1, pos2: integer;
begin
result := '';
pos1 := Pos(Delim1, Str);
if pos1 > 0 then begin
pos2 := PosEx(Delim2, Str, pos1+1);
if pos2 > 0 then
result := Copy(Str, pos1 + 1, pos2 - pos1 - 1);
end;
end;
我在谷歌上搜索后发现需要下载“FastCode.Libraries-0.6.4.zip”,我已经下载了它,但不知道如何使用它来使上面的代码工作。请帮忙!
uses
中是否有StrUtils
? - Martin Melka