- 人气:
- 放大
- 缩小
- 二维码
- 赞赏
delphi 根据关键字取关键词以后的字符串
function GetStrtoend(StrSource, StrBegin: string): string; // (源字符串,开始字符串)
var
in_star: Integer;
begin
in_star := AnsiPos(StrBegin, StrSource);
Result := copy(StrSource, in_star, length(StrSource) - in_star + 1);
end;
procedure TForm1.Button1Click(Sender: TObject);
begin
Memo2.Text:=GetStrtoend(Memo1.Text,'Memo1');
end;