Path: utzoo!attcan!uunet!lll-winken!lll-tis!helios.ee.lbl.gov!pasteur!ucbvax!UIAMVS.BITNET!AWCTTYPA From: AWCTTYPA@UIAMVS.BITNET ("David A. Lyons") Newsgroups: comp.sys.apple Subject: DOS 3.3 text files Message-ID: <8806090321.aa04347@SMOKE.BRL.ARPA> Date: 10 Jun 88 10:20:57 GMT Sender: usenet@ucbvax.BERKELEY.EDU Organization: The Internet Lines: 32 X-Unparsable-Date: Monday 06 Jun 88 3:18 AM CT >From: Michael Williams >Subject: DOS 3.3 Text Files >As a simple example, the following append >program won't work for me. Why not? >100 PRINT "APPENDING F2 TO F1:":PRINT >110 PRINT CHR$(4);"OPEN F2" >120 PRINT CHR$(4);"READ F2" >130 PRINT CHR$(4);"APPEND F1" >140 PRINT CHR$(4);"WRITE F1" >150 ONERR GOTO 500 >160 INPUT X$ >170 PRINT X$; >180 GOTO 160 >500 PRINT CHR$(4);"CLOSE" >510 PRINT "DONE APPENDING" That won't work; every CHR$(4) command cancels any other CHR$(4) command already in effect. You'll have to do a "READ F2" right before the INPUT, and a "WRITE F1" right before the PRINT. Note that you should NOT have a semicolon after that PRINT if you really want to append the files--there won't be any carriage returns added to the file with the semicolon there. >Thanks, >Remo >BIT: WILLIAMS_MS%CUBLDR@VAXF.COLORADO.EDU --David A. Lyons a.k.a. DAL Systems PO Box 287 | North Liberty, IA 52317 BITNET: AWCTTYPA@UIAMVS CompuServe: 72177,3233 GEnie mail: D.LYONS2