Function  GetStr(STR_Source,STR_Start,STR_End:String):STring;
 Var
   I:Integer;
   S:String;
 begin
    for I := Pos(STR_Start,STR_Source)+Length(STR_Start) to Length(STR_Source) do
        begin
          if STR_Source[i]=STR_End then Break;
             S:=S+STR_Source[i];
        end;
        Result:=S;
  end;

我写一个函数主要是用于网页采集。

  STR_Source:采集的内容,如:“账户余额:<b class="forg">2609</b> ”

  STR_Start:所要采集字符的前一个或几个字符,如“账户余额:<b class="forg">”

  STR_End:所要采集字符的后一个字符,如:“<”

最后的返回结果,如“2609”

相关文章:

  • 2021-01-12
  • 2021-01-19
  • 2021-01-26
  • 2021-02-06
  • 2021-02-19
  • 2021-03-01
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2021-11-07
  • 2022-12-23
  • 2022-12-23
  • 2021-07-10
  • 2018-02-05
  • 2021-09-12
  • 2023-02-27
相关资源
相似解决方案