the "array of const" that is the second parameter to
Format
is really an array of TVarRecs
so how about:
procedure TForm1.Button1Click(Sender: TObject);
var args: array of TVarRec; alen:integer; procedure
addString(s:string);
begin alen:=alen+1; setlength(args,alen); with args[alen-1] do begin VType := vtPChar; VPChar := PChar(s); end; end; begin alen:=0; addString('Donovan'); addString('what you'); addString('mind'); ShowMessage (format('%s is this %s had in %s?',args)); end; -ns
|
- [DUG]: [Q] Using Format Function..... Donovan J. Edye
- Re: [DUG]: [Q] Using Format Function..... Nello Sestini
- Re: [DUG]: [Q] Using Format Function..... Donovan J. Edye