Rename file on disk.
Source position: systemh.inc line 1385
procedure Rename( |
var f: file; |
const s: ShortString |
); |
var f: file; |
const p: PAnsiChar |
); |
var f: file; |
const c: AnsiChar |
); |
var f: file; |
const s: UnicodeString |
); |
var f: file; |
const s: RawByteString |
); |
var t: Text; |
const s: shortstring |
); |
var t: Text; |
const p: PAnsiChar |
); |
var t: Text; |
const c: AnsiChar |
); |
var t: Text; |
const s: unicodestring |
); |
var t: Text; |
const s: RawByteString |
); |
Rename changes the name of the assigned file F to S. F must be assigned, but not opened.
Depending on the state of the {$I} switch, a runtime error can be generated if there is an error. In the {$I-} state, use IOResult to check for errors.
|
Delete a file from disk. |
Program Example77; { Program to demonstrate the Rename function. } Var F : Text; begin Assign (F,paramstr(1)); Rename (F,paramstr(2)); end.