Texas Instruments TI89 Developer Guide - Page 609
FOpen, Declaration, Categoryies, Description, Inputs, Outputs, Assumptions
![]() |
UPC - 033317198566
View all Texas Instruments TI89 manuals
Add to My Manuals
Save this manual to your list of manuals |
Page 609 highlights
Appendix A: System Routines - Files 567 FOpen Declaration: Category(ies): Description: Inputs: Outputs: Assumptions: WORD FOpen (const char * fileName, FILES * fsPtr, WORD mode, char * typeName) Files Open a file for a specific mode. fileName - String pointer to name of file to open. fsPtr - Pointer to a structure of type FILES. mode - FM_READ File must exist and can only be read. FM_WRITE Open file for writing and erase its contents. Create file if it does not exist. FM_APPEND If file exists, open it for writing at the end of the file. If it does not exist, then create it and open it for writing. typeName - Must point to a string of, at most, four characters that describes the file type (FS_ERROR is returned if it does not). If there is an existing file with the same name as fileName then the types must match. FS_OK - The file was opened for the specified mode. FS_ERROR - The file cannot be opened for the specified mode (may be locked or is not a third-party data-type). FS_BAD_NAME - fileName is invalid. FS_MEMORY - Not enough memory. The return value is also stored in fsPtr -> fileStatus. The FILES pointer may then be used in subsequent file routines. Filenames are not tokenized variable names (as required by the symbol table code) but rather a string of characters. They must not be reserved names. If a filename does not have a folder name then it will be stored in the current folder. Internally, FILEs are stored as third-party data-types GEN_DATA_TAG). They will show up to the user in the VAR-LINK screen as the type specified when the FILE was opened (up to four letters). (continued) TI-89 / TI-92 Plus Developer Guide Not for Distribution Beta Version January 26, 2001
![](/manual_guide/products/texas-instruments-ti89-developer-guide-95b636f/609.png)