Prototype
TextFileWrite (intFileHandle, strText)
Description
Writes a string in a text file.
Parameters
IntFileHandle: integer value that corresponds at the handle of the file.
Returned value
None.
Notes
None.
Example
// It check if a file exists
Esistente:=FileExists ('c:\text\first.txt');
// If it doesn't exist it creates it
If Esistente=False Then CreateFile('c:\text\first.txt');
// It opens the file
UnFile:=TextFileOpen('c:\text\first.txt',false);
// It reads file contents
text:=TextFileRead(UnFile);
// It writes the word 'Proof' in the opened file.
TextFileWrite(UnFile,'Proof');
// It shows the text of the file in a message erasable by the user
ApplicationLog(_CurrentAgent,'text:' + text);
// Closes the file
TextFileClose(UnFile);