fileEditor()
Opens text files such as .txt and .doc files in an editor. You can edit both plain and rich text.
Synopsis
int fileEditor(string filestr, bool readOnly);
Parameters
Parameter | Description |
---|---|
filestr | File path of the file that will be opened, for example, string filStr = "C:/CTRL_functions/testFile.doc" |
readOnly | 1 = ReadOnly. The file cannot be changed. 0 = the file can be changed. |
Return value
In case of an error, the function returns -1 otherwise, 0.
Error
Missing or wrong parameters.
Description
Opens the file testFile.doc in an editor.
Example
main()
{
bool readOn = 1;
int res;
string filStr = "C:/CTRL_functions/testFile.doc";
res = fileEditor(filStr, readOn);
DebugN(res);
}
Assignment
Simple configuration
Availability
UI