标准的Format函数可以做同样的事情!Format(%。10d,[15])将返回0000000015或者:function AddLeadingZeros(const Source: string; Len: Integer): string;var i: Integer;begin Result := Source; for i := 1 to (Len-Length(Source)) do Result := 0 + Resu
function torehtml(const strHTML: string): string;begin Result :=strHTML; Result := StringReplace(Result, ", ", [rfReplaceAll]); Result := StringReplace(Result, , ', [rfReplaceAl
function StripHTMLTags(const strHTML: string): string;var P: PChar; InTag: Boolean; i, intResultLength: Integer;begin P := PChar(strHTML); Result := ; InTag := False; repeat case P^ of <: InTag := True; >
function GetHTMLColor(cl: TColor; IsBackColor: Boolean): string;var rgbColor: TColorRef;begin if IsBackColor then Result := bg else Result := ; rgbColor := ColorToRGB(cl); Result := Result + color="# + Format(