home *** CD-ROM | disk | FTP | other *** search
/ The Pier Shareware 6 / The_Pier_Shareware_Number_6_(The_Pier_Exchange)_(1995).iso / 013 / bdem22.zip / DEMO.CMP < prev    next >
Text File  |  1994-10-27  |  4KB  |  111 lines

  1. This file contains a list of ALL the program lines that were changed to
  2. create the completed Demo program from the Builder generated output.
  3.  
  4. With the exception of the having to set up the Rel_Maint() function, all
  5. the changes could be done in a matter of 1 or 2 minutes.
  6.  
  7. The listing below contains all the lines of code that have been added,
  8. changed or deleted.  You may look in the DEMO.PR1 and DEMO.PRG files to
  9. confirm this.  For REAL doubting Thomas's, download a copy of Builder,
  10. generate the code and then make the changes yourself.
  11.  
  12. Each line item contains a line number followed by a single character code
  13. to indicate what was done to that particular line of code.  "A" for add,
  14. "C" for change, "D" for delete, and "M" for move.  After that is a greater
  15. than symbol and then the source code line referenced.
  16.  
  17.  
  18. Statistics:
  19. Of the 4844 lines of code generated by Builder for the Demo program...
  20.  
  21.  2 line of code was changed
  22.  3 lines of code were added
  23. 18 lines of code were deleted
  24. --
  25. 23 Total lines of code affected
  26.  
  27. 23/4718 = .00487 = 0.49% of the program lines in the final product are
  28. different from the source originally generated!  1/2 of one percent!
  29. That means 99.51% of the source was created by Builder!
  30.  
  31. Looking at this from another perspective, specifically how much actual
  32. keying is involved.  I added up the number of typed characters it took
  33. to create DEMO.PRG from DEMO.PR1.  I did not include preceding spaces or
  34. the suffixing carriage return.  I did include embedded spaces.  I ended
  35. up with 112 typed characters. (This paragraph is 353 characters long!)
  36.  
  37. DEMO.PR1 is 160,064 bytes in size.
  38. so...112/176,536 = .000634 times 100 (%) = .0634 or .06% meaning:
  39.  
  40. 99.51% of program LINES remained unchanged (from above).
  41. and
  42. 99.94% of the CODE remained unchanged!
  43. You can draw your own conclusions.
  44.  
  45.  
  46. CHANGES MADE TO THE PROGRAM:
  47.  
  48.  
  49.  
  50.  
  51. Deleted and added to convert a "Normal" dialog to one that would save
  52. any changes to some fields of the current OPTIONS.DBF record.
  53. <---------------- demo.pr1 ---------------->
  54. 3891D>      ReadGets(@GetList)
  55. 3892D>
  56. 3893D>      IF LASTKEY() == K_ESC
  57. 3894D>        EXIT
  58. 3895D>      ENDIF
  59. 3896D>
  60. 3897D>      ** Add a command here to execute something after this **
  61. 3898D>      ** dialog box.                                        **
  62. <---------------- demo.prg ---------------->
  63. 3891A>     GetEdit("OPTIONS",WinBott()-1,WinLeft()+2,GetList)
  64. 3892A>     EXIT
  65.  
  66.  
  67.  
  68.  
  69. Changing the Builder gen'd TBrowse code to traverse multiple TBrowse
  70. objects is very simple.  Change the first parm to the BrowseDb() function
  71. so that more than one object is passed.
  72. <---------------- demo.pr1 ---------------->
  73. 4159C>   aBrwObj := { oBrwObj }
  74. 4168D>      Brws152()
  75.  
  76.   In PROCEDURE Brws152 delete these so that the procedure will not execute
  77.   the browse object, but instead will return the object to the calling
  78.   routine.
  79.  
  80. 4300D>   DO WHILE .T.
  81. 4301D>      SetMsgLin("▓ Arrows/PgUp/PgDn-Move ▓ ENTER-Edit ▓ Alt+M-Menu ▓ Ctrl+ENTER-Next ▓ ESC-Exit ▓")
  82. 4302D>      IF !BrowseDb(aBrwObj)
  83. 4303D>         EXIT
  84. 4304D>      ENDIF
  85. 4305D>
  86. 4306D>      // You May Want to Execute Something Here to Follow the Browse
  87. 4307D>   ENDDO
  88. 4308D>   WINDOW REMOVE   // Remove Window from Screen
  89. <---------------- demo.prg ---------------->
  90.   In PROCEDURE Brws146 do this...
  91.  
  92. 4153C>   aBrwObj := { oBrwObj, Brws152() }
  93. 4166A>   WINDOW REMOVE
  94.  
  95. For multiple browses to work, a database RELATION must be established before
  96. the browse is begun.  Be sure to see the hand code section (Hand149) that
  97. calls this browse to see how this can be done.
  98.  
  99.  
  100.  
  101.  
  102. Changed to pass menu control parms to Gen_Maint().  If you do obtain a copy
  103. of Builder v2.2 be sure to look at how the mOpts parameter was passed using
  104. the mechanisms built into Hand Code Sections.  Specifically the @FUNC and
  105. @NXTWNDW Hand Code commands.
  106.  
  107. <---------------- demo.pr1 ---------------->
  108. 4579C>    Gen_Maint(Fmr1,Fmc1,Fmr2,Fmc2,"058",aCities,4,.F.,"ACDF")
  109. <---------------- demo.prg ---------------->
  110. 4564C>    Gen_Maint(Fmr1,Fmc1,Fmr2,Fmc2,"058",aCities,4,.F.,mOpts)
  111.