procedure TForm1.Button1Click(Sender: TObject);begin showmessage(ShowM('22'));end;function TForm1.ShowM(i: string): string;var m:integer; tstring:string;begin tstring:=(i); if length(i)<9 then begin for m:=1 to 8-length(i) do begin tstring:='0'+tstring; end; end; result:=tstring;end;