Product Information > JADE Encyclopaedia of Classes – Volume 1 > Chapter 1 - System Classes > open

open

open();

The open method of the File class opens a file. If you do not explicitly open a file, the first readLine, readString, seek, writeLine, or writeString method opens the file automatically. Before the file is opened, set the FileNode class allowCreate and fileName properties and the File class allowReplace, kind, mode, and shareMode properties, as required.

On Windows Mobile devices, if the value of the kind property is set to Kind_Unknown_Text and the file does not have a Byte Order Mark (BOM) at the start of the file, if the file is zero (0) or 1 byte in length, the file is treated as Kind_ANSI; otherwise it is Kind_Unicode. No attempt is made to detect the file type by reading the first part of the file.

Although you can read and write files of other kinds on Windows Mobile devices, you must explicitly specify the kind of file.