h6. [[OS SWI Calls]] h6(. » OS_Find h2. OS_Find h5. (SWI &0D) |_<^{width:3em}. Entry | | |<^. R0|<^. Reason code, and [[OS_Find Path Bits|path bits]] if reason <> 0| |<^. R1|<^. Filename for opening files, handle otherwise | |<^. R2|<^. Pathname, if 'path used' is 1 or 2| |_<^{width:3em}. Exit | | |<^. R0|<^. File handle or 0 if object doesn't exist (if opening and R0 bit 3 is 0 on entry) | h4. Use The purpose of this call is to either open or close files. h4. Reason Codes |_<^{width:3em}. R0 |_<^. Action | |<^. &00|<^. Closes file R1, or all files if R1 = 0| |<^. &40|<^. Open existing file with read-only access | |<^. &80|<^. Create empty file with read/write access | |<^. &C0|<^. Open existing file with read/write access | h4. See also * [[OS_Find Path Bits]]