home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1993 #3 / NN_1993_3.iso / spool / comp / sys / acorn / 10565 < prev    next >
Encoding:
Text File  |  1993-01-26  |  1.9 KB  |  47 lines

  1. Newsgroups: comp.sys.acorn
  2. Path: sparky!uunet!pipex!pavo.csi.cam.ac.uk!cl.cam.ac.uk!crj10
  3. From: crj10@phx.cam.ac.uk (Clive Jones)
  4. Subject: Re: Help!
  5. Message-ID: <1993Jan26.142450.9008@infodev.cam.ac.uk>
  6. Telephone-Messages: +44 223 33 4900
  7. Sender: news@infodev.cam.ac.uk (USENET news)
  8. Address: Christ's College, Cambridge CB2 3BU, ENGLAND.
  9. Nntp-Posting-Host: fenton.cl.cam.ac.uk
  10. Organization: U of Cambridge, England
  11. References: <93025.092128EY04@LIVERPOOL.AC.UK> <1993Jan25.113557.8389@infodev.cam.ac.uk>
  12. Date: Tue, 26 Jan 1993 14:24:50 GMT
  13. Lines: 32
  14.  
  15. In article <1993Jan25.113557.8389@infodev.cam.ac.uk> MJW19@phx.cam.ac.uk writes:
  16. >In article <93025.092128EY04@LIVERPOOL.AC.UK> EY04@LIVERPOOL.AC.UK writes:
  17. >>I have a BASIC program that I have written for the BBC. Apart from compiling
  18. >>the source code is there any way to prevent the source code from being seen
  19. >>when it is being run on the computer?
  20. >
  21. >I have a small piece of code that converts BASIC programs into executables in a
  22. >rather obvious way. A drawback is that you cannot pass parameters to the BASIC
  23. >program. Once an executable it can be squeeze-d, rendering it unreadable. I'll
  24. >try and dig it out and make it work again, and then maybe post it to Newcastle.
  25.  
  26. Er... for the BBC, though?
  27.  
  28. The following mechanism will work on any machine, although some
  29. cunning is required to drive it from the desktop under RiscOS:
  30.  
  31.   LOAD the basic program.
  32.   PRINT ~PAGE,~TOP
  33.   !(TOP-2)=0
  34.   *SAVE <new-filename> <value-of-PAGE-above> <value-of-TOP-above>
  35.  
  36. This will save a version of the program with the end marker corrupted.
  37. You can then LOAD and RUN the program, but not CHAIN it. Any attempt
  38. to list it, (or any attempt to READ beyond the last DATA statement or
  39. call a missing function/procedure or goto a missing line number) will
  40. give Bad Program. Thus, the program can't be listed, put through
  41. ArmBE, etc.
  42.  
  43. THe slight snag is that you need to *EXEC a script to run it, as I
  44. said.
  45.  
  46. --Clive.
  47.