home *** CD-ROM | disk | FTP | other *** search
- unit CPaU;
-
- interface
- function CPad( X: string; Lngth: integer): string;
-
- implementation
-
- function CPad;
- var Temp: string;
- I: integer;
- begin
- if ord(X[0]) < Lngth then
- begin
- Temp := X;
- while ord(Temp[0]) < Lngth do Temp := ' ' + Temp + ' ';
- end
- else
- Temp := copy(X,1,Lngth);
-
- CPad := copy(Temp,1,Lngth);
- end;
-
- end.
-