home *** CD-ROM | disk | FTP | other *** search
/ Phoenix CD 2.0 / Phoenix_CD.cdr / 01e / makefile.zip / READ.ME < prev   
Text File  |  1988-04-06  |  2KB  |  96 lines

  1.  
  2. Below is a block of code which prepares to call the MAKEFILE.PRG utility.
  3. CREATOR[] is first declared, then the elements are loaded with values which
  4. correspond to the 4 files created with 4 successive calls to MAKEFILE.
  5.  
  6. The following is excerpted from a working program, and only for purpose
  7. of illustrating how to use the MAKEFILE utility:
  8.  
  9. Each file name is represented in a variable, and certain fields' lengths
  10. are represented by variables.
  11.  
  12. clear
  13. @ 10,20 say "Creating new files..."
  14. declare CREATOR[10,4]
  15. **
  16. ** for &topload. - 3 fields, each of length represented in a variable value
  17. **
  18. ** DETAILTEXTCnnn  0
  19. ** TOPIC     Cnnn  0
  20. ** SUBTOPIC  Cnnn  0
  21. **
  22. toploadmin=1
  23. toploadmax=3
  24. CREATOR[1,1]="DETAILTEXT"
  25. CREATOR[1,2]="C"
  26. CREATOR[1,3]=detaillen
  27. CREATOR[1,4]=0
  28. CREATOR[2,1]="TOPIC"
  29. CREATOR[2,2]="C"
  30. CREATOR[2,3]=toplen
  31. CREATOR[2,4]=0
  32. CREATOR[3,1]="SUBTOPIC"
  33. CREATOR[3,2]="C"
  34. CREATOR[3,3]=subtoplen
  35. CREATOR[3,4]=0
  36. **
  37. ** for &topic. - 3 fields, one of whose length is represented in a variable
  38. **
  39. ** TOPIC     Cnnn  0
  40. ** FIRSTSUB  N  6  0
  41. ** LASTSUB   N  6  0
  42. **
  43. topicmin=4
  44. topicmax=6
  45. CREATOR[4,1]="TOPIC"
  46. CREATOR[4,2]="C"
  47. CREATOR[4,3]=toplen + 1
  48. CREATOR[4,4]=0
  49. CREATOR[5,1]="FIRSTSUB"
  50. CREATOR[5,2]="N"
  51. CREATOR[5,3]=6
  52. CREATOR[5,4]=0
  53. CREATOR[6,1]="LASTSUB"
  54. CREATOR[6,2]="N"
  55. CREATOR[6,3]=6
  56. CREATOR[6,4]=0
  57. **
  58. ** for &subtopic. - 3 fields, one of whose length is represented in a variable
  59. **
  60. ** SUBTOPIC  Cnnn  0
  61. ** FIRSTDET  N  6  0
  62. ** LASTDET   N  6  0
  63. **
  64. subtopicmin=7 
  65. subtopicmax=9 
  66. CREATOR[7,1]="SUBTOPIC"
  67. CREATOR[7,2]="C"
  68. CREATOR[7,3]=subtoplen + 1
  69. CREATOR[7,4]=0
  70. CREATOR[8,1]="FIRSTDET"
  71. CREATOR[8,2]="N"
  72. CREATOR[8,3]=6
  73. CREATOR[8,4]=0
  74. CREATOR[9,1]="LASTDET"
  75. CREATOR[9,2]="N"
  76. CREATOR[9,3]=6
  77. CREATOR[9,4]=0
  78. **
  79. ** for &detail. - 1 field with length represented in a variable
  80. **
  81. ** DETAILTEXTCnnn  0
  82. **
  83. detailmin=10
  84. detailmax=10
  85. CREATOR[10,1]="DETAILTEXT"
  86. CREATOR[10,2]="C"
  87. CREATOR[10,3]=detaillen + 1
  88. CREATOR[10,4]=0
  89. ** call makefile to create each
  90. do makefile with topload,toploadmin,toploadmax
  91. do makefile with topic,topicmin,topicmax
  92. do makefile with subtopic,subtopicmin,subtopicmax
  93. do makefile with detail,detailmin,detailmax
  94.  
  95.  
  96.