[Overview][Constants][Types][Classes][Procedures and functions][Variables][Index] |
Write variables to a string
Source position: system.fpd line 60
procedure WriteStr( |
out S: String; |
Args: Arguments |
); |
WriteStr behaves like Write, except that it stores its output in the string variable S instead of a file. Semantically, the WriteStr call is equivalent to writing the arguments to a file using the Write call, and then reading them into S using the Read call from the same file:
var F : Text; begin Rewrite(F); Write(F,Args); Close(F); Reset(F); Read(F,S); Close(F); end;
Obviously, the WriteStr call does not use a temporary file.
WriteStr is defined in the ISO Extended Pascal standard. More information on the allowed arguments and the possible formatting can be found in the description of Write.
|
Write variable to a text file |
|
|
Read variables from a string |
|
|
Read from a text file into variable |
lazarus-ccr.sourceforge.net |