home *** CD-ROM | disk | FTP | other *** search
/ Executor 2.0 / executorv2.0.iso / pc / dos / extra / docs / maillist / text / archive.96 / text4098.txt < prev    next >
Encoding:
Text File  |  1996-07-25  |  2.5 KB  |  65 lines

  1.     id m0u4Ufi-0007rLa; Wed, 3 Apr 96 08:40 MST
  2. Sender: owner-executor
  3. Received: by ftp.ardi.com (Smail3.1.29.1 #3)
  4.     id m0u4UeX-0007rNC; Wed, 3 Apr 96 08:39 MST
  5. Received: from cnc087032.concentric.net (cnc087032.concentric.net [206.173.132.32]) by franklin-fddi.cris.com (8.7.1/(96/04/02 2.25)) id KAA00688; Wed, 3 Apr 1996 10:39:08 -0500 (EST)
  6. Mime-version: 1.0
  7. Message-id: <199604031539.KAA00688@franklin-fddi.cris.com>
  8. Subject: Re: disk images
  9. X-mailer: <PC Eudora Version 1.4>
  10. Content-type: text/plain; charset="us-ascii"
  11. To: Matt `The Man` Galgoci <mjgalgoc@unity.ncsu.edu>, executor@ftp.ardi.com
  12. Date: Wed, 3 Apr 1996 10:39:08 -0500 (EST)
  13. X-sender: johnhess@pop3.cris.com
  14. From: johnhess@cris.com (John Hess)
  15. Sender: owner-executor@ardi.com
  16. Precedence: bulk
  17.  
  18. :At 04:14 PM 4/2/96 -0500, Matt `The Man` Galgoci wrote:
  19. :Hi-
  20. :    I realize that in order to use a disk image as a hfv, the first 
  21. :84 bytes must be stripped off the beginning and the image renamed using 
  22. :*.hfv convention.  Right now, with DOS, I'm not aware of any methods 
  23. :that I can use to do this.  (Yes, I do know how to rename files :-))
  24. :Could a Hex editor be used? How about any of the Norton Utilities?
  25. :- 
  26. :                     North Carolina State University
  27. :                            Matthew John Galgoci
  28. :                          mjgalgoc@unity.ncsu.edu
  29. ::>
  30. :
  31. My question is, how do I get the file to copy back to the DOS area so I CAN 
  32. edit it after I un-hqx/sit/sea it?  If you have the actual image file in 
  33. DOS, you should be able to strip the first 84 bits with the following BASIC 
  34. code.  Note that it is written free-hand on line.  As always when mucking 
  35. about with a file you want to keep, save it somewhere else before mucking 
  36. about with it.
  37.  
  38. 10  Open "filename.ext" for input as #1 
  39. 20  Open "newname.ext" for output as #2
  40. 30  x=1
  41. 40  while not eof(1)
  42. 50  a$=input$(1,1)
  43. 60  if x > 84 then print #2,a$
  44. 70  x=x+1
  45. 80  a$=""
  46. 90  wend
  47.  
  48. Line 10 opens the file to be stripped.  Note that filename.ext represents 
  49. that file's FULL filename
  50. Line 20 opens the file to write the stripped data to.  Again, the FULL filename
  51. Line 30 sets a variable to count the characters
  52. Line 40 sets up a loop that will repeat until the end of the file is reached.
  53. Line 50 gets the next byte in the file
  54. Line 60 discards the first 84 characters and copies the remainder to file 2
  55. Line 70 counts the character position
  56. Line 80 blanks the String variable (may not be necessary, just playing it safe
  57. Line 90 loops back to the line 40 check.
  58.  
  59. Hope this helps.
  60.  
  61.  
  62. John
  63.  
  64.  
  65.