Path: utzoo!utgpu!water!watmath!clyde!rutgers!ucla-cs!zen!ucbvax!OZ.AI.MIT.EDU!GZT.EWW From: GZT.EWW@OZ.AI.MIT.EDU (Wes Williams) Newsgroups: comp.sys.apple Subject: Re: writing ^D in basic Message-ID: <12364975163.63.GZT.EWW@OZ.AI.MIT.EDU> Date: 8 Jan 88 15:17:12 GMT References: <2416@ski.UUCP> Sender: daemon@ucbvax.BERKELEY.EDU Organization: The ARPA Internet Lines: 37 re: ^D statements within a file. OK gang you all got me intrigued! I'm catching up on a weeks mail so pardon if I'm redundant. Point 1. D$ is only a variable. One must create the value of D$ from within a program. 2. The accepted basic standard of D$ is the direct machine command that tells the machine to DO WHAT FOLLOWS the D$ ie ? chr$(4)+"do this". 3. If one wishes to write sompthing to disk as a file the direct command is issued and then the location of the file and then the data. This will result in a text file that then can be read or written to I fail to see the requirement of writing an additional D$ to this text file. Txt files are data. Besides, the resident pgm is still in memory and it knows what D$ is anyway. 4. If one requires a new program to be loaded (even if the name of that program has been manufactured within the current pgm) then in this case the new program will have in it's first few lines 100 D$= chr$(4)+"do this" so the requirement of writing D$ to a file eludes me. 5. The only necessity I can visualize is when one program (current and running) is used to physicaly write another program and then save it. This would appear to be done in a text editor form and done as follows: [remember that this is a text file] 10 D$= chr$(4)+"do this" 20 other parts of pgm and if you must run this program from the previous resident program the last line of the manufactured program would be 100 run and the last line of the manufacturing program would be (linenumber) exec "manufactured program name" lastly at this point I disremenber if a D$ is required prior to the "exec" above. dooos I got it right? -------