OPEN is used to open a file, COM(serial) or LPT(parallel) port.
Syntax 1: OPEN FileName$ FOR Mode AS #FileNumber
FileName$: as a string file name using the DOS 8.3 convention naming limits.
Modes: Open can use 5 different modes:
OUTPUT: Creates a new file or erases an existing file for program output APPEND: Creates a new file or appends data output to an existing file BINARY: Creates a new file or uses input and/or output from an existing file RANDOM: Creates a new file or uses input and/or output from an existing file INPUT : Only reads input from an existing file
FileNumber: as an Integer number or value from FREEFILE