[next] [prev] [prev-tail] [tail] [up]

#### StringOfChar

Declaration:
  Function StringOfChar(c : char;l : Integer) : String;
Description:
  StringOfChar creates a new String of length l and fills it with the character c.

  It is equivalent to the following calls:

       SetLength(StringOfChar,l);
       FillChar(Pointer(StringOfChar)^,Length(StringOfChar),c);

Errors:
  None.
See also:
  SetLength (570)

Listing: refex/ex97.pp

Program Example97;
{$H+}
{ Program to demonstrate the StringOfChar function. }
Var S : String;
begin
S:=StringOfChar(' ',40)+'Aligned at column 41.';
Writeln(s);
end.

[next] [prev] [prev-tail] [front] [up]