home *** CD-ROM | disk | FTP | other *** search
/ Monster Media 1993 #2 / Image.iso / clipper / sld103d.zip / SLD.DOC < prev    next >
Text File  |  1993-05-16  |  104KB  |  2,603 lines

  1.         Screen Layout Designer - V1.03c
  2.         -------------------------------
  3.  
  4.  
  5.                   Chapter 1.
  6.                   ==========
  7.                         
  8. INTRODUCTION
  9. ------------
  10.  
  11. The Screen Layout Designer (SLD) has been designed to create data
  12. entry screens for database applications, such as dBase or
  13. Clipper. Initially it was developed for in house use to assist in
  14. the design of database systems, but it has proved so useful that
  15. it has been enhanced further into a development tool in its own
  16. right.  
  17.  
  18. The Screen Layout Designer will take the drudgery out of
  19. designing data entry screens.  It displays the data fields and
  20. field headings on your screen so that you can use the cursor keys
  21. or a mouse to position them wherever you want.  Additionally you
  22. may add framed boxes and titles to smarten up your data entry
  23. screen.  Colors for the background, data entry fields, headings,
  24. titles, menus and frames are selectable. SLD can read data field
  25. types directly from the header of dBase or Clipper ".DBF" files. 
  26. These fields are then displayed on the screen for you to
  27. manoeuvre into the desired position.  Alternatively SLD can read
  28. the fields from a text file, either created by you manually, or
  29. by dumping the database field definitions into the file by
  30. running a database field listing program, an example of which is
  31. given further in the text.  SLD can also retrieve previously
  32. designed screens from a Screen Layout Definition File, with a
  33. ".SLF" extension.  
  34.  
  35. SLD can generate two types of output file.  The first type is a
  36. text file containing dBase type "@ SAY" and "@ GET" statements,
  37. which may be directly pasted into your dBase or Clipper programs. 
  38. The second type is a Screen Layout Definition File, mentioned
  39. above, which stores full information about fields, boxes, titles
  40. and colors, etc.  You may use almost any programming language to
  41. read these files and extract the information contained in them to
  42. produce data entry screens for almost any database development
  43. language.  Details of these files are given later.   
  44. SLD supports multiple data entry screens.  That is to say if
  45. there are more fields in your database file than can be
  46. accommodated on one screen then you may place them on several
  47. screens.  SLD allows you to move freely between screens and even
  48. to move fields from one screen to another.  You may also change
  49. the text of field headings.  
  50.  
  51. Screen Layout Designer version 1.03 has been developed by Neville
  52. T. Palmer of PDM Associates.  This product is available for you
  53. to copy and pass on to other people, but the copyright remains
  54. the property of PDM Associates and Neville T. Palmer.  You may
  55. use this software initially without charge, but if you intend to
  56. continue using it you should register the product for your use. 
  57. This product is being developed further and there will be
  58. features of later versions which are not yet available in this
  59. one.  Upon registration we will send you the latest version of
  60. this software.  You will also be entitled to generous discounts
  61. on our other programs and future software. Please see appendix D
  62. for information on planned future enhancements, and the section
  63. on registration for information on how to register and to obtain
  64. your free software updates. 
  65.  
  66.                         Chapter 2.
  67.                         ==========
  68.  
  69. INSTALLING SCREEN LAYOUT DESIGNER
  70. ---------------------------------
  71.  
  72. SLD may be installed in any directory of your choice.  You should
  73. copy the files supplied on floppy disk into this directory. If
  74. they are archived then you will need to unarchive them into the
  75. directory.  Here is a full list of files you should have to use
  76. SLD:
  77.  
  78.       SLD.EXE      (the main executable program)
  79.       SLD.OVR      (the overlay file)
  80.       DBFACC.EXE   (the .DBF access program)
  81.       SCREDIT.EXE  (a simple text file editor)
  82.       SETNAME.NAM  (a file containing the name of the setup file  
  83.                         initial default: SETUP.SET)
  84.       SETUP.SET    (a file containing the initial default
  85.                         settings)
  86.       SCRHELP.EXE  (the help program)
  87.       SCRHELP.HLP  (the help file)
  88.       SLD.DOC      (the user manual ... this file)
  89.       SLD.WP5      (the user manual in Wordperfect format)
  90.       README       (a list of these files and initial info)
  91.       TUTOR.DOC    (a tutorial ... also found in the manual)
  92.       REGISTER.DOC (the software registration form for SLD)
  93.        HISTORY.DOC  (history of modifications, etc.)
  94.  
  95.       and sample files as follows:
  96.  
  97.       INPUT.TXT    (a sample input text file)
  98.       COMPANY.DBF  (a sample .DBF file)
  99.       CONTACT.DBF  (ditto)
  100.       OUTPUT.PRG   (a sample screen output file in Clipper 5)
  101.       DBASE3.PRG   (a sample screen output file in dBase III)
  102.       SCREEN.SLF   (a sample screen layout file)
  103.  
  104.       miscellaneous files:
  105.  
  106.        CLIPTEST.PRG (a test program generated by SLD each time a 
  107.                         Clipper program is generated)
  108.       DBTEST.PRG   (a test program generated by SLD each time a
  109.                         dBase program is generated)
  110.       CLIPMAKE.BAT (a batch file which may be used to compile the
  111.                         generated code and test program in
  112.                         Clipper)
  113.  
  114.  
  115.  
  116. STARTING SCREEN LAYOUT DESIGNER
  117. -------------------------------
  118.  
  119. Before running SLD it is best to ensure that no other programs
  120. are running on your system.  To start SLD type 'SLD' at the DOS
  121. prompt. A pull down menu will be displayed.  You will need to
  122. enter systems settings before you can use SLD.  Dependant on the
  123. way you will use SLD you will also have to create certain files
  124. before you can use SLD to build data entry screens (please see
  125. further information below). The most important settings which
  126. you should set from the pull down menu are as follows:
  127.  
  128.   SETUP - select this option from the main menu to enter 
  129.   ====    system settings.
  130.    
  131.       This will take you to a second pulldown menu bar called the
  132.       "System Setup Menu". The most important choices you should
  133.       make from here are:
  134.  
  135.      INPUTTYPE:  -menu option.
  136.      ---------
  137.       You have three choices, "TEXT", "DIRECT" or "SLF". If you
  138.       want to read the data fields direct from a ".DBF" database
  139.       file then you should select "DIRECT".
  140.  
  141.       If you want to read the fields from a text file then you
  142.       should select   "TEXT".  Input text files can be created by
  143.       you either using a text  editor or by running a program
  144.       from Clipper or dBase which dumps the fields to a text
  145.       file. They are also created as an intermediate part of the
  146.       process of reading fields from a .DBF file if you select
  147.       "DIRECT".
  148.  
  149.       You may also read the screen layout which you have
  150.       generated from a previous session.  In this case you should
  151.       select "SLF".
  152.  
  153.       LANGUAGE - menu option
  154.       ---------
  155.       There are slight differences between the dialects of dBase
  156.       generic languages. SLD is equipped to allow for these
  157.       differences in the output screen source code that it
  158.       generates. You may select Clipper V.5, Clipper Summer '87,
  159.       dBaseIII or dBaseIV. SLD will choose the most suitable
  160.       commands for the language that you choose. However if you
  161.       select dBaseIII, certain features of SLD are not available,
  162.       these are:   
  163.         1)  only three box frame types are available instead of
  164.             five (No Frame, Single or Double lined),
  165.         2)  the 43/50 row by 80 column display mode is not
  166.             supported.
  167.       OTHER - menu option
  168.       -----
  169.       
  170.       SETFILE: This is the name of the file which will be used to
  171.             store the system information.  You need not worry
  172.             about this option to begin with , as a default file,
  173.             "SETUP.SET" will already be entered here for you.
  174.   
  175.       EDITOR: You may edit or create the input text file or edit
  176.             the generated screen code file, in which case you
  177.             will require an editor. You may use an editor from
  178.             within SLD, so you should enter the executable name
  179.             of your editor here. The default is the simple built
  180.             in editor "SCREDIT". If you want something more
  181.             sophisticated then your editor should either exist in
  182.             the SLD directory, or in a directory in the DOS path. 
  183.             Do not use a wordprocessor, as it is likely to use
  184.             too much memory and may add unwanted control
  185.             characters to your files.  
  186.  
  187.       SPEED: This setting determines the speed at which messages
  188.             are displayed on the screen. You may select "SLOW",
  189.             "MEDIUM", "FAST" or "FLASH" here, which determines
  190.             the speed at which messages are displayed.
  191.  
  192.       MOUSESPEED: This setting determines the speed of movement
  193.             of the mouse cursor across the screen. You may select
  194.             one of: "VERY SLOW", "SLOW", "MEDIUM", "FAST" and
  195.             "VERY FAST". The optimum setting depends on the mouse
  196.             you are using, the mouse driver software, the speed
  197.             of your computer, as well as personal preference. If
  198.             the mouse cursor moves too fast across the screen as
  199.             you move the mouse, choose a slower setting, and vice
  200.             versa if the cursor moves too slowly.
  201.  
  202.       MAXFIELDS: If you are reading input data fields direct from
  203.             a database .DBF file, or from a text file, the fields
  204.             will be placed on the screen automatically. You will
  205.             need to limit the number of fields placed on any one
  206.             screen to prevent cluttering. When you select this
  207.             option you will be prompted for the number, between 1
  208.             and 50. Save it by pressing the Enter key or Esc to
  209.             quit.  Note that if the screenheight is less than the
  210.             number you enter here this value will be temporarily
  211.             overridden and reduced to the value of the height, in
  212.             number of rows, of the current screen. Also if you
  213.             have entered #SCREEN commands in the input text file,
  214.             these will temporarily override the value.
  215.       REGISTER: This option allows you to register this program
  216.             or check your existing registration. If you intend to
  217.             continue using this software you should register this
  218.             program. If you do so the first screen you see when
  219.             entering SLD will contain your registered name and
  220.             there will be no time delay before the program runs;
  221.             also the exit screen when you leave SLD will no
  222.             longer appear. See the section on Registration for
  223.             full information on how to use this option to
  224.             register this program.
  225.  
  226.       AUTHOR: When you generate the screen code a header will be 
  227.                   written to the top of the file. This will
  228.                   contain the output source code file name and
  229.                   date. It will also contain the registration
  230.                   name if you have registered SLD. You may wish
  231.                   to add an Author name, and selecting this
  232.                   option will allow you to do this.
  233.  
  234.  
  235.       SPLITFILE: You may select "NoSplit" or "Split".
  236.  
  237.             If you select NoSplit:
  238.  
  239.             when you generate the output screen code file
  240.             (usually with a "PRG" file extension) all the code
  241.             will be saved to one file, regardless of how many
  242.             screens you have containing data fields or menus. In
  243.             the case of an FMT file only the screen code for the
  244.             currently active screen number will be saved to the
  245.             FMT file.
  246.  
  247.             Note: the NoSplit option is best suited to Clipper
  248.             programs where multiple screens can be accomodated in
  249.             one program file.
  250.  
  251.             If you select Split:
  252.  
  253.             when you generate the screen code, each screen will
  254.             be saved to a different file with a "Pxx" extension,
  255.             where "xx" is the screen number, eg. screen one may
  256.             be saved to a file called "OUTPUT.P1". In the case of
  257.             FMT files each screen would be saved to a file with
  258.             an "Fxx" extension, where "xx" again is the screen
  259.             number. eg. screen ten may be saved to "OUTPUT.F10".
  260.             When these files have been generated you will
  261.             probably need to rename them to a suitable .PRG or
  262.             .FMT filename.
  263.             
  264.             Notes:
  265.  
  266.             i)  The Split option is better suited to dBase
  267.             programs, especially since dBaseIII may find a single
  268.             file too long to work with.
  269.  
  270.             ii)  The filenames that are used to save the code for
  271.             each screen to will be the name of the Code file or
  272.             FMT file you selected from "File" and "Output" on the
  273.             Main Menu with the new "Pxx" or "Fxx" extension added
  274.             in place of the "PRG" or "FMT" extension.
  275.  
  276.       FILESPERSCREEN: you may select OneOnly or Multiple
  277.             When SLD reads data fields from an input file or
  278.             files you may allow it to display the fields from
  279.             only one data file on each screen or the fields from
  280.             more than one file per screen. 
  281.  
  282.             If you select OneOnly:
  283.  
  284.             If you have setup SLD to read data fields from more
  285.             than one data file those fields will be placed on the
  286.             screen according to the "MaxFields" option, which is
  287.             described above, unless you have set OneOnly here, in
  288.             which case fields from different data files are
  289.             placed on different screens.
  290.  
  291.             If you select Multiple:
  292.  
  293.             In this case fields from different data files may be
  294.             placed on the same screen, and the number of fields
  295.             displayed on one screen will only be determined by
  296.             the "MaxFields" setting.
  297.  
  298.             Note: this setting depends on the intended use of the
  299.             generated code and also which language you are using.
  300.             If you are generating a dBase III/IV screen format
  301.             (FMT) file, normally only fields from one data file
  302.             need be included in one format file.
  303.  
  304.  
  305.  
  306.       DISPLAY - menu option
  307.       -------
  308.       You may select "COLOR" for a color display and "MONO" for a
  309.       monochrome monitor.  In "MONO" mode the display colors are
  310.       clarified for monochrome display. Normally you should opt
  311.       for "COLOR", even on a monochrome display, but if your
  312.       display does not work well in color select MONO.
  313.       From here you may also select "TYPE" so that you can select
  314.       the display adapter type to which your monitor is attached.
  315.       This should be one of "VGA", "EGA", "CGA" or "MDA". See
  316.       below for a further discussion on this. 
  317.       MODE - menu option
  318.       ----
  319.       This option determines the size of your data entry screens
  320.       either 80 columns by 25 rows, 80 columns by 43 rows, or 80
  321.       columns by 50 rows  (dependant on your monitor type).  The
  322.       default is "80x25". See below for further discussion.
  323.  
  324.       PRINTER - menu option.
  325.       -------
  326.       In order to print files and system setting information you
  327.       will need to enter settings relating printer. The printer
  328.       may have a serial or a parallel interface. If it is
  329.       parallel it may be connected to port LPT1, 2 or 3 on your
  330.       computer. If it is serial it may be connected to port COM1,
  331.       2 or 3, and you may need to enter settings relating to the
  332.       communications speed and the size of data bits which for
  333.       characters which will be sent to your printer. The setup
  334.       information may be entered as follows:
  335.  
  336.       PORT:  this is the port on your computer to which the
  337.             printer will be attached and should be one of
  338.             LPT1,LPT2,LPT3 for parallel, or COM1, COM2 or COM3
  339.             for serial printer interfaces.
  340.  
  341.       COMMS: if you are using a printer with a serial interface 
  342.                   having selected one of COM1-3, you may need to
  343.                   change  the port communication speed and data
  344.                   bits to match the printer. The options from
  345.                   this submenu are:
  346.  
  347.         Speed -   one of 9600, 4800, 2400 or 1200 bauds. This is
  348.                   the rate of data transfer to your printer.
  349.         Data  -   this is the number of data bits for each
  350.                   character sent to the printer, either 7 or 8.
  351.         Parity-   this may be Even, Odd or None, depending on the
  352.                   type of data parity error checking your printer
  353.                   requires.
  354.         Stop -    this is the number of stop bits that are added
  355.                   to the end of each character sent to the
  356.                   printer, either one or two.
  357.  
  358. For information on which printer settings to select you should
  359. consult your printer manual. If your printer has a parallel
  360. interface you do not need to change any of the settings available
  361. from the "COMMS" option, but if it has a serial interface you may
  362. need to. You should ensure that you have the correct cable
  363. attached to your printer, especially in the case of serial
  364. communications where you will need to ensure that correct
  365. handshaking takes place between the computer and printer. There
  366. are no facilities for changing handshaking modes from SLD at the
  367. moment, so ensure that you have a cable capable of dealing with
  368. hardware or software handshaking.
  369.       SAVE - menu option.
  370.       ----
  371.       Once you have entered the settings you should save them by
  372.       selecting this option.
  373.  
  374.       Now return to the Main Menu by selecting "MAINMENU" or
  375.       pressing "ESC".
  376.  
  377.  
  378.  
  379.             FROM THE MAIN MENU:
  380.             -------------------
  381.  
  382.       FILE - menu option. Select this option from the Main Menu.
  383.       ----
  384.  
  385.        INPUT: If you have selected "DIRECT" from the INPUTTYPE
  386.             option of the System Setup Menu, then you will need
  387.             to enter the name of the .DBF file that SLD will read
  388.             data fields from, and the name of an intermediate
  389.             text file into which the fields will be held for use
  390.             by SLD. In this case enter the name of the text file
  391.             by selecting "TEXT" and then the name of the .DBF
  392.             file by selecting "DBASE".
  393.  
  394.             If you have selected "TEXT" from the INPUT option on
  395.             the System Setup Menu then you only need to enter the
  396.             name of the text file here, in the same way.
  397.             Remember, if you elect to do this the text file must
  398.             already exist, having been created manually or by
  399.             dumping fields from a .DBF file into the text file.
  400.  
  401.             If you have selected "SLF" from the INPUTTYPE option
  402.             you must enter the name of a previously generated
  403.             Screen Layout File, with an ".SLF" extension, created
  404.             by you during a previous SLD session.
  405.  
  406.  
  407.       OUTPUT: You must select "CODE" to enter the name of the
  408.             file which will contain your dBase generic language
  409.             screen source code. You must select "SLF" to enter
  410.             the name of a Screen Layout File which will be used
  411.             to store the screen layout and settings from the
  412.             current SLD session.
  413. Using MonoChrome Monitors with SLD.
  414. -----------------------------------
  415. Ideally Screen Layout Designer is used to best effect on a color
  416. monitor, however you may be using a monochrome monitor, or simply
  417. wish to generate source code for mono monitors. To select
  418. monochrome display mode you may either select Setup/Display/Mono
  419. from the menu bar after starting SLD, or you may start SLD with
  420. the "/M" switch, ie. type the following at the DOS prompt:   
  421. SLD /M.  This will override the default colors. If you then
  422. change the colors when in SLD you should save them.  If you do
  423. this you will not need to use the /M switch, which overrides all
  424. color settings, when you next run the program.
  425.  
  426. The color palette is available for you to change colors in Mono
  427. mode, but they are translated into the gray scale tones
  428. automatically so that what you see is actually what you get when
  429. code is generated.
  430.  
  431. Some mono monitors have been found to display well in Color
  432. display mode, but others display better in Mono mode.
  433.  
  434.  
  435.  
  436.  
  437. Selecting a Display Adapter Type:
  438. --------------------------------
  439. When you initially setup SLD you should select SETUP from the
  440. Main Menu. This will take you to the Setup Menu. Enter the other
  441. settings as normal. To change the display adapter type, select
  442. MODE followed by TYPE. You may select MDA for Monochrome and
  443. Hercules display adapters, CGA for the original Color Graphics
  444. Adapter, EGA for the Enhanced Graphics Adapter, or VGA for Video
  445. Graphics Array adapter (including SVGA, etc.). Selecting the
  446. correct display adapter will ensure that you do not select an
  447. incorrect display mode.
  448.  
  449.  
  450. Selecting Text Mode.
  451. --------------------
  452. The display mode that you select will determine the appearance of
  453. your data entry screen in the finished dBase/Clipper program. The
  454. display modes are: 25 rows x 80 columns, 43 x 80, and 50 x 80.
  455. There are a number of factors which determine valid display modes
  456. as follows:
  457.  
  458.  1)   your display adapter and monitor type,
  459.  2)   which output language you will use (dBaseIII or IV, or 
  460.       Clipper V5 or S87).
  461.  3)   the version of DOS on the program development PC.
  462. SLD attempts to be as flexible as possible in the above issues.
  463. Here is a breakdown of valid display modes:
  464.  
  465.  1)   The CGA display adapter generally only allows 25 x 80 
  466.       display mode. MDA and Hercules monochrome, and EGA color
  467.       adapters generally allow only 25 x 80, and 43 x 80 display
  468.       modes. VGA adapters generally allow  25 x80, 43 x 80 and 50
  469.       x 80 modes, however SLD only supports 43 x 80 mode on a VGA
  470.       adapter with DOS version 4 and above.
  471.  
  472.  2)   dBaseIII and Clipper 87 only support 25 x 80 mode. dBaseIV 
  473.       supports 25 x 80 and 43 x 80 modes. Clipper V5 supports 25
  474.       x 80, 43 x 80 and 50 x 80 modes.
  475.  
  476. To select a text mode select SETUP from the Main Menu to display
  477. the Setup Menu. From this menu select MODE. You may then select
  478. one of the three modes, dependant on the adapter type you have
  479. entered in the TYPE option on this menu. If you change mode the
  480. contents of the screen will be cleared and regenerated in the new
  481. mode.
  482.  
  483.  
  484. NOTES:
  485. ------
  486. You should change the display mode before you have allowed SLD to
  487. read data fields from a file and display them on the screen (by
  488. selecting SHOW from the Main Menu). If you do not the screen you
  489. were editing could be truncated, particularly if you switch from
  490. 50 x 80 to 25 x 80 mode, and some fields may not be displayed.
  491. Should this happen, switch back to the previous mode and move the
  492. fields to within the bounds of the new screen mode, or,
  493. alternatively, move the fields to another screen.  eg. if you
  494. wish to switch from 50 x 80 to 25 x 80, then move the relevant
  495. field's position on the screen above the 25 row boundary, or move
  496. it onto the next screen.
  497.  
  498. Select the best screen mode for the output language you are
  499. using. For instance, don't select 50 x 80 mode when your target
  500. language is dBaseIII. SLD is flexible; you might say that it
  501. gives the user enough rope to hang themselves with!
  502.    
  503.                               Chapter 3.
  504.                               ==========
  505.  
  506. USING SCREEN LAYOUT DESIGNER.
  507. -----------------------------
  508.  
  509. Having setup the important initial settings in SETUP and FILE
  510. from the pulldown menu you are ready to view and edit the data
  511. fields on screen.
  512.  
  513. To do this select "SHOW" from the main pull down menu.  The pull
  514. down menu will disappear and the fields will be displayed with
  515. their headings.  A second menu will appear superimposed on the
  516. fields; this is the Screen Edit Menu. If you are reading from a
  517. .DBF or text file the data fields and default headings will be
  518. displayed starting from top left.  To start editing the screen
  519. select EDITSCREEN from the pulldown menu or just press "Esc".
  520. You are in Screen Edit Mode. NOTE: to get back to the pull down
  521. menu from within your editing session  press "Esc" again.  To
  522. move the cursor you may use the cursor (arrow) keys or a mouse.
  523.  
  524. Note:  if to return to the main menu from the Screen Edit Menu,
  525.       select "QUIT"  (or "Alt Q").
  526.  
  527.  
  528. Manoeuvring the Fields and Headings.
  529. -------------------------------------
  530. You may use the cursor keys  or mouse to manoeuvre the fields and
  531. headings around the screen.  To move a field or heading, move the
  532. cursor onto it with the mouse or cursor keys and press the Enter
  533. key or press the left mouse button.  If you are using a mouse,
  534. keep the left button pressed and move the field to the new
  535. position, then release the button.  If you are using the cursor
  536. keys, move the field to the new position and press enter again to
  537. place it. 
  538.  
  539. Other Cursor Movement Keys.
  540. ---------------------------
  541. In addition to the mouse and cursor keys (arrow keys) you may use
  542. other keyboard keys to move the cursor around the screen as
  543. follows:
  544.       HOME - to move the cursor to the far left of the screen.
  545.       END  - to move the cursor to the far right of the screen.
  546.       PAGE_UP - to move the cursor to the top of the screen.
  547.       PAGE_DOWN -to move the cursor to the bottom of the screen.
  548.  
  549.  
  550. Changing Headings & the Screen On Which a Field/Heading Appears.
  551. ---------------------------------------------------------------
  552. If you move the cursor onto a field or heading with the mouse or
  553. cursor keys and, either press function key F2, or double click
  554. the mouse, a window will appear containing the following
  555. information on that field:
  556.  
  557. Field Name: the name of the data field as it appears in the .DBF
  558.             file.
  559. Type: the type of the field (C=character, N=numeric, D=date,
  560.       M=memo, L=logical)
  561. Width: the width of the data field
  562. Decimal Places:   the number of decimal places for numeric
  563.                   fields.
  564.  
  565. From here you can change the heading text which corresponds to
  566. the data field on the screen, and the screen on which the field
  567. and its heading are displayed.  In version 1.03 of SLD you will
  568. only be able to change these two items.  To change the heading,
  569. simply type in the new text. If you do not want any heading for
  570. this field (eg. for ADDRESS2,3,4 fields) delete the heading,
  571. leaving the text blank, and the heading will not appear on the
  572. screen when you save the information.
  573.  
  574.  
  575. If you want the field and its heading to be displayed on another
  576. screen, enter the new screen number here, and when you save the
  577. information the field and heading will disappear from the current
  578. screen.  The field and heading will reappear when you select the
  579. new screen from the menu bar. To save and exit the window, press
  580. Ctrl and Enter.  To exit without saving the changes, press Esc. 
  581. Or you may delete a field and its heading completely by pressing
  582. the F4 key.  If you do so the field and heading will disappear
  583. from all screens.  You should consider very carefully whether you
  584. need the field you are about to delete before actually deleting
  585. it. If you delete it then your program will not be able to update
  586. information in this field for each record in your data file, with
  587. the code generated in this session.
  588.  
  589.  
  590. Moving to Another Screen.
  591. ------------------------
  592. If you press "Esc" whilst in Screen Edit Mode the pulldown Screen
  593. Edit Menu will reappear.  To change to another screen select the
  594. "SCREEN" option from here.  You are given three choices: "NEXT"
  595. to move to the next screen, "PREV" to move to the previous
  596. screen, and "NUMBER" which will prompt you to enter a screen
  597. number to move to.  If the screen you select is out of range you
  598. will be warned accordingly.
  599.  
  600. You may also select a screen by number from the main menu SCREEN
  601. option. Adding a Blank Screen.
  602. ----------------------
  603. You may add a blank screen to the current editing session from
  604. the Main Menu bar or from the Screen Edit Menu by selecting
  605. "SCREEN", followed by "ADD".  If are in Screen Edit Mode you
  606. should press "Alt" and "S" (or press "Esc" to return to the
  607. Screen Edit Menu and select "SCREEN") so that you can select
  608. "ADD" to append a new screen to your session.
  609.  
  610.  
  611. Adding Boxes and Titles to your Screens.
  612. ---------------------------------------
  613. To improve the presentation of your data entry screens you can
  614. add framed
  615. boxes and additional titles to them.  
  616.  
  617. To Add a Box:
  618. -------------
  619. You may add a box from the Screen Edit Menu by selecting "BOX".
  620. From here
  621. you may add a NEW box, EDIT or DELETE an existing one. If you are
  622. in Screen Edit Mode you may press "Alt" and "B" which will take
  623. you straight to the new box menu option on the Screen Edit Menu
  624. (you may also do this by pressing "Esc" and then selecting "BOX"
  625. from the menu). Before adding your box you may wish to change the
  626. type of frame you want for the box, in which case select "FRAME"
  627. first.  The frame type you select will override the default frame
  628. setting.  Having selected the frame you should then select "NEW".
  629. The pulldown menu will disappear and you will enter Screen Edit
  630. Mode and then Box Edit Mode.  Move the cursor, using the cursor
  631. keys or mouse, to the position where you want the top left corner
  632. of the box to start, then press Enter, or click with the mouse.
  633. Now when you move the cursor the box will expand or contract from
  634. its origin.  When the box is at its correct size you may move it
  635. around the screen by pressing F3.  F3 can be used to toggle
  636. between moving the box or expanding/contracting it.  When you are
  637. happy with the size and position of the box, click with the mouse
  638. or press Enter to save it, or to abandon the box press Esc.
  639.  
  640. To edit or delete a box select "EDIT" or "DELETE" from the BOX
  641. option on the menu.  Move the cursor to the box to edit or delete
  642. and either click on it with the mouse or press Enter.  If you are
  643. deleting the box you will be asked whether you wish to go ahead
  644. with the deletion.  If you answer "Y" the box will disappear. If
  645. are editing the box you will enter Box Edit mode and you should
  646. progress as mentioned previously when adding a box.
  647.  
  648. Hotkey to Add a Box.
  649. --------------------
  650. If you are in Screen Edit Mode you may add a box without
  651. resorting to the pulldown menu bar.  If you press F3 you will
  652. enter Box Edit Mode, from where you can place a box on the
  653. screen.  Note however that you cannot use F3 to edit or delete an
  654. existing box.
  655. To Add a Title:
  656. --------------
  657. You may add a box from the Screen Edit Menu by selecting "TITLE".
  658. From here you may add a NEW title, EDIT or DELETE an existing
  659. one. If you are in Screen Edit Mode you may press "Alt" and "T"
  660. which will take you straight to the new title menu option on the
  661. Screen Edit Menu (you may also do this by pressing "Esc" and then
  662. selecting "TITLE" from the menu). The pulldown menu will
  663. disappear and a window will appear prompting you to enter the
  664. title text.  The title text can be up to 78 characters in length. 
  665. Leading spaces will may be used to left pad the title. To save
  666. the title text press Enter (to exit without saving press Esc).
  667. You will enter Screen Edit Mode and then Title Edit Mode.  Move
  668. the cursor, using the cursor keys or mouse, to the position where
  669. you want the left side of the title to start, then press Enter,
  670. or click with the mouse.  Now when you move the cursor the title
  671. will expand or contract from its origin. When the title is at its
  672. correct size you may move it around the screen by pressing F3. 
  673. F3 can be used to toggle between moving the title or
  674. expanding/contracting it.  When you are happy with the size and
  675. position of the title, click with the mouse or press Enter to
  676. save, or press Esc to abandon it.
  677.  
  678. To edit or delete a box select "EDIT" or "DELETE" from the TITLE
  679. option on the menu.  Move the cursor to the title to edit or
  680. delete and either click on it with the mouse or press Enter.  If
  681. you are deleting the title you will be asked whether you wish to
  682. go ahead with the deletion.  If you answer "Y" the title will
  683. disappear.  If are editing the title a window will appear
  684. enabling you to edit the title text as previously.  When you have
  685. changed the text save it with Enter, or press Esc to abandon the
  686. edit. You will then enter Title Edit mode and you should progress
  687. as mentioned previously when adding a Title.
  688.  
  689. Hotkey to Add a Title.
  690. ----------------------
  691. If you are in Screen Edit Mode you may add a title without
  692. resorting to the pulldown menu bar.  If you press F4 you will
  693. enter Title Edit Mode, from where you can place a title on the
  694. screen.  Note however that you cannot use F4 to edit or delete an
  695. existing title.
  696.  
  697. Adding Menu Systems and Options your Screens.
  698. ---------------------------------------------
  699. To improve the functionality of your data entry screens you can
  700. add menu sytems to them.  To each menu system you may can add a
  701. number of menu options.
  702.  
  703. To Add a Menu System:
  704. ---------------------
  705. From the Screen Edit Menu select "MENU" and then "ADD" .  From
  706. here you can add a new menu system. The menu system will be added
  707. to the current screen on view. You should plan your menus and
  708. remember not to clutter your screens with too many menus.
  709.  
  710.  
  711. dBase II and IV Menus:
  712. ----------------------
  713. If the language you are using is dBase III or IV then you may use
  714. one of 3 slightly different menu types. When adding a new menu
  715. you will first of all be prompted: 
  716. "Use Conventional dBase Menu style (Y/N)?". 
  717. If you answer "NO" to this the menu generated will be a bounce
  718. bar type, and if you answer "YES" the menu will be of the
  719. conventional dBase type. If you do answer "YES" you will be
  720. prompted: 
  721. "Use an @GET to Select menu options (Y/N)?". 
  722. If you select "NO" to this the user's menu choice will be input
  723. by an INKEY() statement, but if you answer "YES" the user's
  724. choice will be input by an @GET and you will be prompted for the
  725. row and column where you wish the @GET prompt to be initially
  726. placed on the screen. If you answer "YES" you should save the row
  727. and column that you have entered by pressing the "Ctrl" and
  728. "Enter" keys. If you press the "Esc" key you will be returned the
  729. the previous "(Y?N)?" prompt. Remember that if you are adding
  730. more than one menu to the screen the @GET prompt should be placed
  731. in a different position for each menu. In any case you may move
  732. the prompt later by entering Menu Edit Mode.
  733.  
  734. Note: if you add a conventional dBase menu system without an @GET
  735. to select options on this menu then you may only add a maximum of
  736. nine selectable options to this menu. This type of menu is
  737. available for efficient small menus for dBase applications. Adding Options to Menus:
  738. ------------------------
  739. Once you have created your menu system it will be of no use until
  740. you have added menu options to it. To add an option select
  741. "MENU", then "OPTION", followed by "NEW" from the Screen Edit
  742. Menu.  NOTE: If you are in Screen Edit Mode you may get straight
  743. to here by pressing "Alt" and "M".
  744.  
  745. You will be prompted to enter the heading text for the menu
  746. option you are adding and the number of the menu system on which
  747. it will appear. The heading may be up to 40 characters, for
  748. example you may have a heading of "EDIT" on your menu. If you are
  749. unsure of which menus are active on the screen in view, press the
  750. F3 key and you will be presented with a list box of available
  751. menu numbers active on this screen. You should use the up or down
  752. arrow keys to highlight a menu number and select it using the
  753. Enter key. To save the heading and menu number information press
  754. "Ctrl" and "Enter", or "Esc" to abandon the whole operation.
  755.  
  756. If you save the menu heading information you will enter Screen
  757. Edit Mode and then Menu Edit Mode.  Move the cursor, using the
  758. cursor keys or mouse, to the position where you want the left
  759. side of the menu option to start, then press Enter, or click with
  760. the mouse. When you move the cursor keys or mouse the menu option
  761. will expand or contract it from its origin.  When the menu option
  762. is at its correct size you may move it around the screen by
  763. pressing F3.  F3 can be used to toggle between moving the option
  764. or expanding/contracting it.  When you are happy with the size
  765. and position of the menu option, click with the mouse or press
  766. Enter to save it. 
  767.  
  768.  
  769. To edit or delete a menu option select "EDIT" or "DELETE" from
  770. MENU/OPTION  on the menu.  Move the cursor to the menu option to
  771. edit or delete and either click on it with the mouse or press
  772. Enter.  If you are deleting the option you will be asked whether
  773. you wish to go ahead with the deletion.  If you answer "Y" the
  774. menu option will disappear.  If are editing the option a window
  775. will appear enabling you to edit the menu option text as
  776. previously.  You may also attach the menu option to another menu
  777. system. 
  778. When you have changed the text save it with Enter, or press Esc
  779. to abandon the edit. You will then enter Menu Edit mode and you
  780. should progress as mentionedpreviously when adding a menu option.
  781.  
  782. Hotkey to Add a Menu Option.
  783. ---------------------------
  784. If you are in Screen Edit Mode you may add a menu option without
  785. resorting to the pulldown menu bar.  If you press F5 you will
  786. enter Menu Edit Mode, from where you can place a menu option on
  787. the screen.  Note however that you cannot use F5 to edit or
  788. delete an existing menu option.
  789. Adding a Standard Menu System.
  790. -----------------------------
  791. To save you the time taken in creating a standard menu system,
  792. you may select a Standard menu from the Screen Edit Menu. This
  793. standard menu has seven options already created for you, these
  794. are: "ADD", "EDIT", "DELETE", "NEXT", "PREV", "FIND" and "QUIT".
  795. These menu options are drawn on the second to last row of the
  796. current screen when you select "MENU", followed by "STANDARD",
  797. from the Screen Edit Menu. You may only add one standard menu to
  798. each screen. These menu options may be edited in the same way as
  799. previosuly described.
  800.  
  801. Letter Selection of dBase Menus.
  802. --------------------------------
  803. To improve your dBaseIII/IV menus you may wish to select a menu
  804. option by pressing a letter, rather than using the cursor/tab key
  805. to highlight it and then pressing the enter key. For example: if
  806. you have amenu option called "EDIT" you may wish to select it by
  807. simply pressing the letter "E".  To enable letter selection then,
  808. when you edit the menu option heading, insert a ^ (hat) symbol
  809. before the selection letter (normally the first letter). The
  810. ^ symbol will not appear on the finished menu system, but the
  811. letter selection code will be generated. (So then in our example
  812. we would enter the option title as "^EDIT" ). Note that when you
  813. select the standard menu system the ^ symbol is added before
  814. the first character of each option automatically.
  815.  
  816.  
  817. Notes: 
  818.  
  819. 1)    in the case of Clipper menus it is not necessary to include
  820.       the ^ symbol in option headings because Clipper
  821.       automatically allows first letter selection in menus.
  822.  
  823. 2)    If you select Clipper for the Language setting, then
  824.       generate a Standard Menu, and you then change the language
  825.       to dBase, remember that the Standard Menu will have no ^
  826.       symbols for first letter selection.
  827.  
  828.  
  829. The Expand/Contract or Move HotKey - F3
  830. ----------------------------------------
  831. It is worth emphasising that when editing Boxes, Titles or Menu
  832. options and moving them around the screen the F3 key toggles
  833. between movement of the object and expanding/contracting the size
  834. of the object.
  835. CHANGING DEFAULT COLORS FOR GENERATED SCREENS.
  836. ----------------------------------------------
  837.  
  838. If you select "SCREENCOLORS" from Main Menu, at any time, you
  839. will be able to change the colors, etc, of the data entry screen
  840. you will generate (NOTE: this should not be confused with the
  841. system colors for SLD system menus and windows available from the
  842. Setup Menu).
  843.  
  844. The settings you can change from SCREENCOLORS are as follows:
  845.  
  846.  BACKFILL:  this option allows you to change the character that
  847.             will be used to fill the background of your data
  848.             entry screen. It may be a space character, or ASCII
  849.             code.
  850.  
  851.  BACKGROUND: this allows you to change the background color of 
  852.             the data entry screen.  The actual color and
  853.             appearance of the background will depend on the
  854.             combination of this setting and the BACKFILL
  855.             character you selected.
  856.  
  857.  FIELD:     this determines the color of text and background of
  858.             unselected data entry fields.  To assist you in
  859.             choosing the color of the field text, an asterisk is
  860.             displayed in the blank field.
  861.  
  862.  SELECTED:  this determines the text and background color in
  863.             which the currently selected data entry field will
  864.             appear. 
  865.  HEADING:   this allows you to select the text and background 
  866.             color for headings which correspond to a data entry
  867.             field.
  868.  
  869.  TITLE:     this option allows you to select the text and
  870.             background color for additional titles on your data
  871.             entry screen.
  872.  
  873.  MENU:      this option allows you to select the text and
  874.             background color for selected user created menu
  875.             options. These menus should not be confused with the
  876.             main SLD pulldown menu bar.
  877.  
  878.  UNSELMENU: this allows you to select the text and background
  879.             color for unselected user created menu options.
  880.  
  881.  BOX:       this determines the frame background and foreground
  882.             color of boxes you add to your data entry screen.
  883.  
  884.  FRAME:     you can select the default frame characters which
  885.             boxes will use by default.  This setting can be
  886.             overridden temporarily when you add a new box.  The
  887.             frame you may select can be one of: No Frame, Single
  888.             Lined Frame, Double Lined Frame, Double Lined Top and
  889.             Single Lined Side, or Single Lined Top and Double
  890.             Lined side.
  891.  
  892.  SETFRAMES: if you change the default frame type this change will
  893.             not be reflected in the previously defined boxes
  894.             already displayed on the screen, unless you change
  895.             each box individually. However by selecting this
  896.             option all boxes will be updated with the new default
  897.             frame type at the same time.
  898.  
  899.   Note:     if you are using the monochrome display mode the
  900.             color palette colors will be translated to gray scale
  901.             tones. Some colors in the palette will be displayed
  902.             with an underline. These colors will be displayed
  903.             with underlining in the system colors, and on
  904.             completed data entry screens if you have selected
  905.             Clipper for the language type. However the
  906.             underlining will not be displayed if you select dBase
  907.             for the language type, so bear this in mind when
  908.             selecting colors.
  909. CHANGING DEFAULT SLD SYSTEM COLORS.
  910. -----------------------------------
  911. If you select "SETUP" from Main Menu, the System Setup Menu will
  912. appear. You may change the default system settings for Screen
  913. Layout Designer from here. By selecting "COLORS" you may change
  914. the colors for the pulldown menus, information windows/dialog
  915. boxes, data entry, and listboxes, etc.
  916.  
  917. The settings you can change from COLORS are as follows:
  918.  
  919.  MENUBAR - this option allows the setting of pulldown menu colors
  920.  -------
  921.  UNSELECTED: this option allows you to change the color of        
  922.             currently unselected options on the pulldown menus.
  923.  
  924.  HIGHLIGHT: unselected menu options have a highlighted character.
  925.             If you select "Alt" and this character, or just this
  926.             character on its own you will select this option on
  927.             the menu. You may change the highlight color here.
  928.  
  929.  SELECTED:  this option allows you to change the color of the
  930.             currently selected menu option.
  931.  
  932.  DISABLED:  some menu options will not be valid for the state of
  933.             the current menu. These options will disabled and
  934.             should appear in a dimmer color than normal selected
  935.             or unselected options. Change this color here.
  936.  
  937.  FRAME:     this option allows you to change the frame and
  938.             heading text color of pulldown menus.
  939.  
  940.  HELP:      this option allows the setting of the single help
  941.             line positioned at the bottom of the screen.
  942.  
  943.  WINDOWS - this option allows the setting of windows/dialog box -
  944. -------   colors.
  945.  
  946.    TEXT:    this option allows you to change the color of the
  947.             text of information and dialog boxes,as well as the
  948.             background on which it is displayed.
  949.  
  950.    FRAME:   this allows you to change the frame color for info.
  951.             windows and dialog boxes.
  952.  
  953.    SBUTTON: some dialog boxes will present you with options
  954.             presented as buttons responding to operator response
  955.             (eg. 'Y' or 'N'). You to change the color of the
  956.             currently selected push button.
  957.  
  958.    UBUTTON: this allows you to change the color of currently
  959.             unselected push buttons.
  960.  
  961.   ENTRY - this option allows the setting of data entry box colors
  962.   -----
  963.    WINDOW:  this option allows you to change the frame, heading 
  964.             and background colors for data entry windows
  965.             requiring user input (eg. the name of a file for SLD
  966.             to process).
  967.  
  968.    PROMPT:  this option allows you to change the text and
  969.             background color for the text prompting the user for
  970.             data entry. (eg. Filename: ).
  971.  
  972.    SELECTED: this allows you to change the color of the currently
  973.             selected item in in a data entry window.
  974.  
  975.    UNSELECTED: if there is more than one item in a data entry
  976.             window the currently unselected items will be
  977.             presented in a different color to the selected item.
  978.             You may change this color here.
  979.  
  980.   LISTBOX - this option allows the setting of listbox colors.
  981.   --------  Listboxes will present the user with multiple lines
  982.             of information and may also allow the user to select
  983.             a line for input into a data entry screen.
  984.  
  985.   FRAME:    this allows you to change the color of the frame
  986.             surrounding a list box.
  987.  
  988.   HIGHLIGHT: this allows you to change the color of the
  989.             currently highlighted line in a list box.
  990.  
  991.   NORMAL:   this allows you to change the color of all other
  992.             non-highlighted items in a list box.
  993.  
  994.  
  995.   HELP  - this option allows you to change the help window
  996.   ------  and index colors.
  997.  
  998.    FRAME:   this allows you to change the color of the frame and
  999.             heading colors of the help window and help index.
  1000.  
  1001.    NORMAL:  this allows you to change the background and text
  1002.             color for of the help window and index.
  1003.  
  1004.    HIGHLIGHT: this allows you to change the color of higlighted
  1005.             words within the help window (ie. for important
  1006.             titles and points).
  1007.  
  1008.    INDEX:   the index window highlights the currently selected
  1009.             index topic. This allows you to change the the color
  1010.             of the highlighted item.
  1011.              
  1012. GENERATING SCREEN OUTPUT SOURCE CODE.
  1013. -------------------------------------
  1014.  
  1015. Once you have laid out your data entry screen(s), complete with
  1016. any necessary boxes and titles, you are ready to generate source
  1017. code so that the screen can be incorporated into the database
  1018. program under development.
  1019.  
  1020. The built in code generator will generate code in dBase or
  1021. Clipper generic code.  To generate the code you should ensure
  1022. that you have entered a file name in the FILE/OUTPUT/CODE option
  1023. from the pulldown menu bar, then you should select "GEN" from the
  1024. menu bar, followed by "CODE".  The source code for the screen(s)
  1025. will be placed in the selected file. You should then paste the
  1026. code into your program and compile it with your dBase generic
  1027. compiler.  The code will be in the form of a procedure.  If your
  1028. program will incorporate multiple data entry screens then one
  1029. procedure will be generated for each screen.  Please see Appendix
  1030. B for information on the code generated by SLD.
  1031.  
  1032. The default filename extension for generated Screen Code Files is
  1033. ".PRG". 
  1034.  
  1035.  
  1036. GENERATING A SCREEN LAYOUT FILE.
  1037. --------------------------------
  1038.  
  1039. In addition to source code, you can store the contents and
  1040. settings of a data entry screen you have laid out in a type of
  1041. file unique to SLD.  This file contains a header record and a
  1042. record for each screen you have assigned in the current session. 
  1043. The Screen Layout Files have a ".SLF" extension name.  Once you
  1044. have laid out your screen(s) you can generatean SLF, first
  1045. ensuring that you have entered a file name with the correct
  1046. extension in the FILE/OUTPUT/SLF option from the pulldown menu
  1047. bar.  To generate the SLF select "GEN", followed by "SLF" from
  1048. the menu bar. The full information and settings relating to the
  1049. current screen(s) will be stored in the selected Screen Layout
  1050. File.
  1051.  
  1052. At any time in the future you can read from this SLF by selecting
  1053. SETUP/INPUT/SLF from the menu bar and entering its file name when
  1054. you select FILE/INPUT/SLF.  Then when you select VIEW the
  1055. previously stored screen will be redisplayed.
  1056. This type of file is probably the most powerful feature of SLD
  1057. because any third party program can be written to read its
  1058. contents to generate screen code in almost any language.  This
  1059. feature is one being developed further.
  1060.  
  1061. For information on the fields in the records of a Screen Layout
  1062. File please see Appendix A.
  1063.  
  1064.  
  1065. UPDATING THE INPUT TEXT FILE.
  1066. -----------------------------
  1067.  
  1068. If you are reading the data fields direct from a .DBF file then
  1069. an intermediate input text file will be created.  You may also
  1070. create your own text file containing the data fields, either
  1071. manually with an editor (see Chapter 4), or by dumping the fields
  1072. from a .DBF file into a text file (a program example, written in
  1073. Clipper is given in Chapter 4).  Screen Layout Designer will read
  1074. the data fields from this text file.  You may update the contents
  1075. of this file, in a limited way, by selecting "UPDATE", followed
  1076. by "TEXT", from the menu bar.  The data fields listed in the text
  1077. file will be saved in the order in which they appear on the
  1078. screen you have laid out, and according to them screen number on
  1079. which they appear.  The update operation may make use of the
  1080. #SCREEN command, unique to SLD.  
  1081.  
  1082. NOTE: beware that if you have updated the text file and you are
  1083. reading direct from a database .DBF file, the text file will be
  1084. overwritten when you re-run SLD or select NEW from the menu bar,
  1085. unless you select a new text file name for input.
  1086.  
  1087.  
  1088.  
  1089. EDITING A FILE.
  1090. ----------------
  1091.  
  1092. You may edit an input text file (default extension .TXT), an
  1093. output Screen Code File (default extension .PRG), or a dBase FMT
  1094. file (default extension .FMT), but you should not attempt to edit
  1095. any other type of file used by SLD.  Before you can edit a file
  1096. you must ensure that a valid editor has been selected.  The
  1097. executable file name of your editor should be entered by
  1098. selecting SETUP, then EDITOR from the menu bar. The default
  1099. editor is SCREDIT.EXE, however you may want to use a more
  1100. sophisticated editor.  Do not use a wordprocessor from within
  1101. SLD, as it is likely to use too much memory and may add unwanted
  1102. control characters to the file being edited.  If you have to use
  1103. a wordprocessor use it outside of the SLD program and save your
  1104. files as ASCII text, without control characters.
  1105.  
  1106. To edit the input text file select "EDIT", followed by "INPUT"
  1107. from the pulldown menu bar, then enter the name of the input text
  1108. file you wish to edit.  The default file extension for input text
  1109. files is ".TXT". 
  1110. To edit the output Screen Code File select "EDIT", followed by
  1111. "OUTPUT" from the menu bar, then enter the output Screen Code
  1112. File name that you wish to edit.  The default file extension for
  1113. Screen Code files is ".PRG".
  1114.  
  1115. To edit a dBase FMT file select "EDIT", followed by "FMT". The
  1116. default extension for these files is ".FMT".
  1117.  
  1118.  
  1119. PRINTING A FILE.
  1120. ----------------
  1121.  
  1122. You may print an input text file (default extension .TXT), an
  1123. output Screen Code File (default extension .PRG), or a dBase FMT
  1124. file (default extension .FMT), but you should not attempt to
  1125. print any other type of file used by SLD. You may additionally
  1126. print information about the current system settings. The
  1127. information is sent to the printer in normal ASCII text form. 
  1128. Before printing you must ensure that you have selected the
  1129. correct printer port for your printer. This should be LPT1, LPT2,
  1130. LPT3, COM1, COM2 or COM3, depending on whether your printer
  1131. interface is parallel or serial, and on how many ports your
  1132. system has free and available. To setup the printer, run the
  1133. Setup Menu, by selecting "SETUP" from the Main Menu, and then
  1134. select "PRINTER". You should enter the printer port and other
  1135. information here (see Setup).
  1136.  
  1137. To print the input text file select "PRINT", followed by "INPUT"
  1138. from the Main Menu bar. The file to be printed will be the input
  1139. text file name that you have entered by selecting "File", "Input"
  1140. and "Text" from the Main Menu.
  1141.  
  1142.  
  1143. To print the output Screen Code File select "PRINT", followed by
  1144. "OUTPUT" from the Main Menu. The file to be printed will be the
  1145. output program file name that you have entered by selecting
  1146. "File", "Output" and "Code" from the Main Menu.
  1147.  
  1148. To edit a dBase FMT file select "PRINT", followed by "FMT". The
  1149. file to be printed will be the input text file name that you have
  1150. entered by selecting "File", "Output" and "FMT" from the Main
  1151. Menu.
  1152.  
  1153. To print information about the current system setup select
  1154. "PRINT" followed by "SETTINGS". 
  1155.  
  1156. SELECTING A NEW INPUT FILE.
  1157. ---------------------------
  1158.  
  1159. You do not need to exit Screen Layout Designer to clear the
  1160. screen and read data fields from a new file.  If you select "NEW"
  1161. from the menu bar you will be able to clear the current fields
  1162. from the screen and either re-read the current input file, or
  1163. read a new input file.  If you have not saved the current screen
  1164. and settings you will be prompted to save them before reading of
  1165. the new input file commences.
  1166.  
  1167.  
  1168. USING ONLINE HELP.
  1169. ------------------
  1170.  
  1171. A HELP option is available from the pulldown menu.  This is
  1172. effectively an online manual with an index of topics.  If you are
  1173. stuck at any point then pressing "Esc" will get you out of
  1174. trouble and take you back to the menu bar, where you can select
  1175. online help which will be of assistance to you in the task you
  1176. are trying to perform.
  1177.  
  1178.  
  1179. LEAVING THE PROGRAM.
  1180. --------------------
  1181.  
  1182. To Exit SLD from Screen Edit Mode, press "Esc" until the menu bar
  1183. appears.  From the main pulldown menu bar press "Esc" again to
  1184. quit the program.  If you have not saved your screen and settings
  1185. you will be prompted to do so. 
  1186.  
  1187.  
  1188.                         Chapter 4.
  1189.                         ==========
  1190.  
  1191. CREATING AN INPUT TEXT FILE.
  1192. ----------------------------
  1193.                         
  1194. If you opt to read data fields onto your screen by
  1195. directlyreading from a database .DBF file then Screen Layout
  1196. Designer will automatically create an intermediate text file for
  1197. you.  You can use the file thus created in future screen editing
  1198. sessions without having to re-read the database file.   
  1199.  
  1200. If you do not want to read fields directly from the database file
  1201. then you can create the text file in two ways:
  1202.  
  1203. 1)    by running a program which lists the fields from your
  1204.       database file and dumps them into the text file.
  1205. 2)    by using an editor to create the file manually yourself.
  1206.  
  1207.  
  1208. Method 1:
  1209. ---------
  1210. Here is a sample program, written in Clipper, which can be used
  1211. to read the structure of a database file, in this case MEDIA.DBF,
  1212. and copy the field information into a text file, in this case
  1213. INPUT.TXT:
  1214.  
  1215. use MEDIA
  1216. COPY STRUCTURE EXTENDED TO newlist
  1217. USE newlist
  1218. LIST field_name,field_type,field_len,field_dec TO FILE input.txt
  1219.  
  1220.  
  1221. The above program is all you need to create the input text file. 
  1222. You might call this program "STRUC.PRG" and then compile it using
  1223. the Clipper compiler.  When you run the executable, STRUC.EXE,
  1224. you will create the text file.  (Note that newlist is an
  1225. intermediate file).
  1226.  
  1227. Method 2:
  1228. ---------
  1229. You can get an initial idea of how to create a text file manually
  1230. by looking at the sample file INPUT.TXT supplied on the
  1231. distribution disks.  The text file must contain, for each field,
  1232. the field name, field type, field length and decimal places (for
  1233. numeric types).  The field types can be one of: C (character), D
  1234. (date), N (numeric) or M (memo).  Here is an example:
  1235.  
  1236.       SHORTCODE C 10  0
  1237.       ACCNO     C 10  0  
  1238.       COMPANY   C 30  0  
  1239.       ADDRESS1  C 30  0  
  1240.       ADDRESS2  C 30  0  
  1241.       ADDRESS3  C 30  0  
  1242.       ADDRESS4  C 30  0  
  1243.       POSTCODE  C 15  0
  1244.  
  1245.  
  1246. Each line corresponding to each field can optionally be prefixed
  1247. by a number for compatibility reasons, although SLD ignores the
  1248. number. For example:
  1249.  
  1250.       1     SHORTCODE C 10  0
  1251.       2     ACCNO     C 10  0
  1252.       3     COMPANY   C 30  0
  1253.       4     ADDRESS1  C 30  0
  1254.       5     ADDRESS2  C 30  0
  1255.       6     ADDRESS3  C 30  0
  1256.       7     ADDRESS4  C 30  0
  1257.       8     POSTCODE  C 15  0
  1258.  
  1259.  
  1260. In addition the file can contain a "#SCREEN" command, unique to
  1261. SLD, which splits a number of fields into screens.  This command
  1262. is the only "hash" command currently supported by SLD. The syntax
  1263. is:     #SCREEN  <number>
  1264. where "number" is the screen number.  All data fields after the
  1265. #SCREEN command will be placed onto the screen with the specified
  1266. number, until another #SCREEN command is encountered.   Note:
  1267. When you do not include a #SCREEN command in the input text file
  1268. SLD automatically splits the screens for you, but if you include
  1269. #SCREEN commands SLD allows these to split the screens, so be
  1270. careful that you do not try to push too many fields onto one
  1271. screen. Example:
  1272.  
  1273.       #SCREEN 1
  1274.  
  1275.       SHORTCODE C 10  0
  1276.       ACCNO     C 10  0
  1277.       COMPANY   C 30  0
  1278.  
  1279.       #SCREEN 2
  1280.  
  1281.       ADDRESS1  C 30  0
  1282.       ADDRESS2  C 30  0
  1283.       ADDRESS3  C 30  0
  1284.       ADDRESS4  C 30  0
  1285.       POSTCODE  C 15  0
  1286.       
  1287. In the above example, SHORTCODE, ACCNO and COMPANY will appear on
  1288. screen number 1 and ADDRESS1,2,3,4 and POSTCODE will appear on
  1289. screen 2.
  1290.  
  1291.  
  1292. Multiple Database Files.
  1293. ------------------------
  1294. You may enter fields from more than one databse file on you data
  1295. entry screens. This features allows SLD to produce relational
  1296. applications. The layout is as follows:
  1297.  
  1298. COMPANY->SHORTCODE C 10  0
  1299. COMPANY->ACCNO     C 10  0
  1300. COMPANY->COMPANY   C 30  0
  1301. COMPANY->ADDRESS1  C 30  0
  1302. COMNPNY->ADDRESS2  C 30  0
  1303. COMPANY->ADDRESS3  C 30  0
  1304. COMPANY->ADDRESS4  C 30  0
  1305. COMPANY->POSTCODE  C 15  0
  1306. CONTACTS->SHORTNAME C 10 0
  1307. CONTACTS->FIRSTNAME C 30 0
  1308. CONTACTS->SURNAME   C 30 0
  1309.  
  1310. Two data files are used in the example above, COMPANY and
  1311. CONTACTS, so that fields from both files will appear on the same
  1312. screen.
  1313.  
  1314.  
  1315. As previously mentioned SLD will automatically generate an
  1316. intermediate text file for you if you opt to read the database
  1317. fields directly from  database .DBF files. However you may wish
  1318. to edit the input text file to suit your needs.                         APPENDIX A.
  1319.                         ===========
  1320. THE FORMAT OF SCREEN LAYOUT FILES.
  1321. ----------------------------------
  1322. The format of SLF files have changed. The older format is however
  1323. still supported by the later releases of SLD.
  1324.  
  1325. Screen Layout Files (SLF) contain full information about screens
  1326. that you have built, plus other settings, including colors.  Each
  1327. SLF has a 222 byte header record, followed by a 109 byte record
  1328. for each field, box or title on all active screens.  The file
  1329. looks like this:
  1330.  
  1331.           byte
  1332.           pos'n
  1333.           -----
  1334.              1  _______________
  1335.                |    Header     |
  1336.            223 |---------------|
  1337.                |  Field Info.  |
  1338.            332 |---------------|
  1339.                |  Field Info.  |
  1340.            441 |---------------|
  1341.                |  Field Info.  |
  1342.            550 |---------------|
  1343.                     etc...
  1344.  
  1345. The Header Record will be as follows:
  1346.  
  1347. Byte   Data
  1348. Pos'n  Type     Purpose of Data
  1349. -----  ------   -----------------------
  1350.  1     byte     Color used for background of data entry screen
  1351.  2     byte     Color used for unselected data entry fields
  1352.  3     byte     Color used for selected data entry fields
  1353.  4     byte     Color used for data entry field headings
  1354.  5     byte     Color used for additional titles
  1355.  6     byte     Color used for boxes
  1356.  7     byte     Color used for selected menu options
  1357.  8     byte     Color used for unselected menu options
  1358.  9     char     ASCII character used for background
  1359. 10     Boolean  Text mode (true=80x25, false=80x50)
  1360. 11     byte     Language type (1=Cl5, 2=Cl87, 3=DB3, 4=DB4)
  1361. 12     Boolean  Use a space after field headings.
  1362. 13-102 array of 10 strings of length 8 bytes, containing
  1363.        .DBF filenames
  1364. 103    Boolean  Monochrome colors (true=mono, false=color)
  1365. 104    byte     Default frame type (see table)
  1366. 105    byte     Number of active data fields on the screen(s)
  1367. 106    byte     Number of boxes on the data entry screen(s)
  1368. 107    byte     Number of titles on the data entry screen(s)
  1369. 108    byte     Maximum number of screens active in this session
  1370. 109    byte     Number of menus on the data entry screen(s)
  1371. 110-149 array of bytes (1 to max. menu number) one byte for each
  1372.       active menu containing the screen on which it appears.
  1373. 150    byte     Display type (1=MDA, 2=CGA, 3=EGA, 4=VGA)
  1374. 151    byte     Display rows (25, 43 or 50)
  1375. 152    byte     Dos version no.
  1376. 153-168 array of bytes - Each bit of 16 bytes representing a 
  1377.       screen, if the bit is set it has a standard menu on it.
  1378. 169-208 array of bytes (1 to max menu no.) one byte for each 
  1379.       active menu containing menu type.
  1380. 209-216 byte    reserved
  1381. 217-220 byte    Representing ASCII characters giving 'END$'
  1382. 221    byte     byte value for SLD file type (3 = 1.03b)
  1383. 222    byte     reserved
  1384.  
  1385. The frame types are numbered.  This number represents frame types
  1386. as follows:
  1387.  
  1388.  0 = No Frame
  1389.  1 = Single Frame  (ASCII codes 218,192,191,217,196,179)
  1390.  2 = Double Frame  (ASCII codes 201,200,187,188,205,186)
  1391.  3 = Single Top Double Sided (ASCII 214,211,183,189,196,186)
  1392.  4 = Double Top Single Sided (ASCII 213,212,184,190,205,179)
  1393.  
  1394.  
  1395. Following the header, information relating to each active data
  1396. field for the session being recorded is stored in the form of one
  1397. record field, including its heading, as follows:
  1398.  
  1399. Byte
  1400. Pos'n
  1401. From  Data
  1402. Start Type        Purpose of Data
  1403. ----- ------      ---------------------------
  1404.   1   double byte Field reference number
  1405.   3   byte        DBF file number (this number corresponds to an
  1406.                   index in the array of DBF files in the header)
  1407.   4   string[10]  Field name in the database file
  1408.  15   string[78]  Heading as it appears on screen for this field
  1409.  94   character   The data type of this field (C,N,D, or M)
  1410.  95   byte        The length of the field
  1411.  96   byte        The number of decimal places (numeric fields)
  1412.  97   byte        Left column of start of data entry field on
  1413.                   screen
  1414.  98   byte        Top row of start of data entry field
  1415.  99   byte        Right column of data entry field
  1416. 100   byte        Bottom row of data entry field (same as top)
  1417. 101   byte        Left column of start of field heading on screen
  1418. 102   byte        Top row of field heading
  1419. 103   byte        Right column of field heading
  1420. 104   byte        Bottom row of field heading (same as top)
  1421. 105   byte        The screen number on which this field appears
  1422. 106   byte        (reserved for boxes,titles and menus... see
  1423.                   below)
  1424. 107   byte        Color attribute of unselected data entry fields
  1425. 108   byte        Color attribute of field headings
  1426. 109   byte        Color attribute of selected data entry fields
  1427.  
  1428. Note: the color attributes for individual fields are not
  1429. currently supported.
  1430.  
  1431. After the fields have been stored, information on titles and menu
  1432. options will be stored in the same manner, with one record per
  1433. title or per menu option. The record format is identical to that
  1434. used for the data entry fields, however the record fields are
  1435. re-used. The only differences between titles and menu options
  1436. are: (a) the title type is 'T', whereas this will be 'Y' or 'Z'
  1437. for menus,  (b) a byte is used to store the menu system number in
  1438. the case of menu options, and this will be 0 for titles. The
  1439. information will be stored as follows:
  1440.  
  1441.       Data
  1442. Byte  Type        Purpose of Data
  1443. ----  ------      -----------------------------------
  1444.   1   double byte Reference number
  1445.   3   byte        unused
  1446.   4   string[10]  unused
  1447.  15   string[78]  This contains the text for this title
  1448.  94   character   The data type of this field = 'T' for a title,
  1449.                   but 'Y' or 'Z' for menu options.
  1450.  95   byte        unused
  1451.  96   byte        unused
  1452.  97   byte        Left column of start of title/menu option on
  1453.                   screen
  1454.  98   byte        Row of title
  1455.  99   byte        Right column of title/menu option
  1456. 100   byte        unused
  1457. 101   byte        unused
  1458. 102   byte        unused
  1459. 103   byte        unused
  1460. 104   byte        unused
  1461. 105   byte        The screen number on which this title/menu
  1462.                   option appears.
  1463. 106   byte        must always be set to 0 for titles, but in the
  1464.                   case of menu options this must be the menu
  1465.                   system number on which this menu option
  1466.                   appears.
  1467. 107   byte        Color attribute for this title or menu option.
  1468. 108   byte        unused
  1469. 109   byte        unused
  1470.  
  1471. Note: the color attributes for individual titles or menu options 
  1472.       are not currently supported.
  1473.  
  1474. After the title and menu records, information relating to Boxes
  1475. on the screen(s) will be stored in a similarly.  The record
  1476. fields are re-used as follows:
  1477.  
  1478.       Data
  1479. Byte  Type        Purpose of Data
  1480. ----  ------      -----------------------------------
  1481.   1   double byte Reference number
  1482.   3   byte        unused
  1483.   4   string[10]  unused
  1484.  15   string[78]  unused
  1485.  94   character   The data type of this field = 'X' for boxes
  1486.  95   byte        unused
  1487.  96   byte        unused
  1488.  97   byte        Left column of start of box on screen
  1489.  98   byte        Top row of box
  1490.  99   byte        Right column of box
  1491. 100   byte        Bottom row of box
  1492. 101   byte        unused
  1493. 102   byte        unused
  1494. 103   byte        unused
  1495. 104   byte        unused
  1496. 105   byte        The screen number on which this box appears
  1497. 106   byte        The frame type number for this box (see above)
  1498. 107   byte        Color attribute for this box
  1499. 108   byte        unused
  1500. 109   byte        unused
  1501.  
  1502. Note: the color attribute for individual boxes is not currently
  1503. supported.
  1504.  
  1505.  
  1506.                         Appendix B.
  1507.                         ===========
  1508.  
  1509. THE GENERATED SCREEN CODE.
  1510. --------------------------
  1511.  
  1512. The Screen Layout Designer is capable of producing dBase generic
  1513. source code directly.  The source code representing the screens
  1514. that you have laid out will be stored in a text file which may
  1515. bepasted directly into your dBase generic program source code. 
  1516. You can then compile this code, using your dBase generic
  1517. compiler, into an executable ".EXE" file.  
  1518.  
  1519. The default extension for files containing generated screen code
  1520. is ".PRG". 
  1521.  
  1522. When you select dBase language generation a "MAIN.PRG" file will
  1523. be generated for you to enable you to test the code in the
  1524. generated .PRG file. This file may form the basis for your
  1525. application, though you should obviously rename it if you make
  1526. changes to it.
  1527.  
  1528. FMT FILES
  1529. ---------
  1530. SLD version 1.03 is also capable of producing dBaseIII "FMT"
  1531. files.  These FMT files contain only @SAY and @GET statements
  1532. corresponding to data entry fields and headings. Any menus, boxes
  1533. or titles you have laid out on the screen will not be included.
  1534. The default extension for these files is ".FMT".
  1535.  
  1536.  
  1537. The source code will be generated as follows:
  1538.  
  1539. Start and End of a Screen.
  1540. --------------------------
  1541. The contents of each screen will be placed in a procedure,
  1542. beginning with:
  1543.  
  1544.  PROC SCREEN#     ,where # is the screen number, and ending with:
  1545.  RETURN
  1546.  
  1547.  
  1548. Colors for Screens.
  1549. ------------------
  1550. Colors for each screen as a whole, boxes or titles will be set by
  1551. the following command:
  1552.  
  1553.  SET COLOR TO <expC1>,<expC2>,<expC3>,<expC4>,<expC5>
  1554.  
  1555. where expC1 = standard color, expC2 = enhanced color, expC3 =
  1556. border color, expC4 is left blank, expC5 = unselected color.  
  1557. For example:
  1558.  
  1559.  SET COLOR TO "GR+/R,BG+/R,W+/G,,N/W"
  1560.  
  1561.  In the case of Clipper V5 this will take the form of:
  1562.  
  1563.  SETCOLOR("GR+/R,BG+/R,W+/G,,N/W")
  1564.  
  1565.  
  1566. Drawing Boxes.
  1567. ---------------
  1568. Boxes are drawn with the following command syntax for Clipper:
  1569.   
  1570.   @ <toprow>,<leftcol>,<botrow>,<rightcol> BOX <frame> COLOR
  1571. <color>
  1572.  
  1573. For example:
  1574.  
  1575.   @ 13,32,17,62 BOX "┌─┐│┘─" COLOR "W+/G"
  1576.  
  1577.  
  1578. In the case of dBaseIII the box drawing is different:
  1579. Firstly the colors are set, then the box may have a double or
  1580. single lined frame:
  1581.  
  1582.   @ <toprow>,<leftcol> TO <botrow>,<rightcol> [DOUBLE]
  1583.  
  1584. Note: "DOUBLE" is omitted in the case of single lined frames.
  1585.  
  1586. Example:
  1587.  
  1588.       SET COLOR TO "W+/G"
  1589.       @ 8,36 TO 13,54 DOUBLE
  1590.       SET COLOR TO "GR+/RB,N/BG,,,N/W"
  1591.  
  1592.  
  1593. For dBaseIV the code will be similar to this example:
  1594.  
  1595.       SET COLOR TO "W+/G"
  1596.       @ 8,36 TO 13,55 "┌─┐│┘─└│"
  1597.       SET COLOR TO "GR+/RB,N/BG,,,N/W"
  1598.  
  1599. Titles.
  1600. -------
  1601. The command syntax for titles will be a simple @SAY statement,
  1602. preceded by coloring information:
  1603.  
  1604.      @ <row>,<col> SAY  "<text>"
  1605.  
  1606. For example:
  1607.   
  1608.    @  1,12  SAY "   Sales Database  "
  1609.  
  1610.  
  1611.  
  1612. Data Entry Fields.
  1613. ------------------
  1614. The colors for unselected and selected data entry fields will be
  1615. taken from the SET COLOR command immediately preceding the @GET
  1616. commands.  The data entry field code will be as follows:
  1617.  
  1618.    @ <row>,<col>  GET  <field_name>
  1619.  
  1620. For example:
  1621.  
  1622.    @ 3,17 GET company
  1623.  
  1624.  
  1625. Data Field Headings.
  1626. --------------------
  1627. The headings corresponding to data entry fields will be generated
  1628. using @SAY statements as follows:
  1629.  
  1630.    @ <row>,<col>  SAY  <heading>
  1631.  
  1632. For example:
  1633.  
  1634.    @ 3,5  SAY  "Company Name"
  1635.  
  1636.  
  1637. Reading Data Fields.
  1638. --------------------
  1639. The @GET statements in a procedure are terminated with a 
  1640. READ command.
  1641.  
  1642.  
  1643.  
  1644. Menu Systems
  1645. ------------
  1646. The way in which menus are implemented in Clipper differs from
  1647. dBase. In Clipper @PROMPT commands are used to build the menu and
  1648. the selected menu option stored using a MENU TO MKey command. In
  1649. the case of dBase menus the process of menu building is more
  1650. complicated, and an example is more suitable to illustrate this.
  1651. Each menu system is formed by a separate procedure in which the
  1652. menu is defined and laid out on the screen. This procedure is
  1653. called:
  1654. PROCEDURE MENU#   ,where # is the menu number.
  1655. Another procedure contains CASE statements where appropriate
  1656. action is taken in accordance with the selected menu option. 
  1657. This is called:
  1658. PROCEDURE MENUCASE#   ,where # is the menu number.
  1659.  
  1660. Clipper menu syntax:
  1661. -------------------
  1662. The menu is defined within the MENU# procedure:
  1663.  
  1664. To define a menu option:
  1665.  
  1666.   @ <row>,<col> PROMPT <heading>  MESSAGE <message>
  1667.  
  1668. Foe example:
  1669.  
  1670.   @ 14,20 PROMPT "QUIT" MESSAGE " "
  1671.  
  1672. Note that the message is blank, but you may add your own help
  1673. text.
  1674.  
  1675. Storing the menu to a variable:
  1676.  
  1677.   MENU TO <key>
  1678.  
  1679. For example:
  1680.  
  1681. MENU TO MKey
  1682.  
  1683. dBaseIII/IV Menus
  1684. -----------------
  1685. This is rather more complicated. Please study the sample program
  1686. DBASE3.PRG.
  1687.  
  1688. The last statement before RETURN in the MENU# procedure should
  1689. be a call to the procedure containing CASE statements:
  1690.   DO MENUCASE#
  1691. Clipper example:
  1692.  
  1693.   PROCEDURE MENU1
  1694.     LOCAL MKey
  1695.     @ 1,1 PROMPT "SAVE" MESSAGE " "
  1696.     @ 3,1 PROMPT "QUIT" MESSAGE " "
  1697.     MENU TO MKey
  1698.     DO MENUCASE1 WITH MKey
  1699.   RETURN
  1700.  
  1701.  
  1702. To Define the Menu Case Statements:
  1703. ----------------------------------
  1704. As mentioned previously the final stage of the menu process is a
  1705. separate procedure in which CASE statements perform appropriate
  1706. action according to the selected key from the menu.  The syntax
  1707. for this procedure is as follows:
  1708.  
  1709. PROCEDURE MENUCASE#
  1710.    PARAMETER <key>
  1711.    DO CASE
  1712.        CASE <key> = 1
  1713.          DO <procedure>
  1714.        CASE <key> = 2
  1715.          DO <procedure>
  1716.        ....
  1717.        ....
  1718.    ENDCASE
  1719. RETURN
  1720.  
  1721.  
  1722. For example:
  1723.  
  1724.  PROCEDURE MENUCASE1
  1725.    PARAMETER MKey
  1726.    DO CASE
  1727.       CASE MKey = 1
  1728.         DO SaveIt
  1729.       CASE MKey = 2
  1730.         RETURN
  1731.    ENDCASE
  1732.  RETURN
  1733.  
  1734.  
  1735. Note: SLD directs the case statements to a dummy procedure with
  1736.       DO DUMMY.  You should enter your own user defined procedure
  1737.       in each case statement. The DUMMY procedure is defined as:
  1738.       PROCEDURE DUMMY 
  1739.       RETURN
  1740.  
  1741. Selecting Menu Options at Runtime.
  1742. ---------------------------------
  1743. When you have generated the code for your menus you may, in
  1744. addition to first letter selection, select menu options when you
  1745. run the program as follows:
  1746.  
  1747.   dBaseIII/IV:    using the tab key, or the up or down  arrow
  1748.                   keys.
  1749.   Clipper:  using the cursor keys (arrow keys).
  1750.  
  1751.  
  1752.  
  1753. How the Generated Source Code is Constructed.
  1754. --------------------------------------------
  1755. The source code is formed of several modules. Each screen has its
  1756. own associated set of procedures, which are as follows:
  1757.  
  1758. Procedure 1: Displays titles and framed boxes, @SAY and @GETs for
  1759.             the data field memory variables.
  1760. Procedure 2: Declares data field memory variables corresponding
  1761.             to the open database fields. They are declared as
  1762.             PUBLIC.
  1763. Procedure 3: Initialises the memory variables so that they do
  1764.             not contain garbage.
  1765. Procedure 4: sets the memory variables to the contents of the
  1766.             database fields, so that editing procedures can make
  1767.             use of this.
  1768. Procedure 5: replaces the database field values with the values
  1769.             of the corresponding memory variables.
  1770. Procedure 6: this is a dummy procedure used by case statements
  1771.             in menus for testing purposes only.
  1772. Procedure 7: this defines menus and the menu options, and passes
  1773.             a menu selection to the next procedure.
  1774. Procedure 8: this is a series of case statements which act on the
  1775.             appropriate menu selection in procedure 7. The case
  1776.             statements call the dummy procedure at the moment
  1777.             -you should replace this with your own procedures.
  1778.  
  1779.  
  1780. An Example of Generated Screen Source Code.
  1781. --------------------------------------------
  1782. There are sample programs supplied with .PRG file extensions.
  1783. These will undoubtedly give you more insight into how SLD
  1784. generates its screen code. Howeever here is a simple single
  1785. screen example of the typical output of the Screen Layout
  1786. Designer.  It includes, boxes, a title, and data fields, with
  1787. appropriate headings:
  1788.  PROCEDURE SCREEN1
  1789.  
  1790.   LOCAL WinStr,iRow
  1791.  
  1792.     SETMODE(25,80)
  1793.  
  1794.       WinStr=""
  1795.       SETCOLOR("B+/B")
  1796.       FOR iRow = 0 TO 25
  1797.         @ iRow,0 SAY PADC(WinStr,80,"░")
  1798.       NEXT
  1799.  
  1800.       SETCOLOR("W+/BG")
  1801.       @ 0,0,24,79 BOX "┌─┐│┘─└│"
  1802.  
  1803.       SETCOLOR("GR+/R,W/R,,,N/W")
  1804.       @ 2,25 SAY "    ACME Sales Database   "
  1805.  
  1806.       SETCOLOR("GR+/RB,N/BG,,,N/W")
  1807.  
  1808.       @ 4,8 SAY "Short Name "
  1809.       @ 6,11 SAY "Company "
  1810.       @ 8,11 SAY "Address "
  1811.       @ 9,20 SAY aADDRESS2 PICTURE "XXXXXXXXXX"
  1812.       @ 10,20 SAY aADDRESS3 PICTURE "XXXXXXXXXX"
  1813.       @ 11,14 SAY "City "
  1814.       @ 13,5 SAY "Zip/Post Code "
  1815.       @ 15,15 SAY "Tel "
  1816.       @ 16,15 SAY "Fax "
  1817.       @ 18,9 SAY "Sales Area "
  1818.       @ 20,9 SAY "Sales Rep. "
  1819.       @ 18,44 SAY "Credit Limit "
  1820.       @ 14,43 SAY "Business Type "
  1821.       @ 4,39 SAY "Account No. "
  1822.       @ 16,48 SAY "Turnover "
  1823.       @ 20,46 SAY "Last Order "
  1824.      DO GETSCR1
  1825.      DO MENU2
  1826.  
  1827.  RETURN
  1828.  
  1829.  PROCEDURE SCREEN2
  1830.  
  1831.   LOCAL WinStr,iRow
  1832.  
  1833.     SETMODE(25,80)
  1834.  
  1835.       WinStr=""
  1836.       SETCOLOR("B+/B")
  1837.       FOR iRow = 0 TO 25
  1838.         @ iRow,0 SAY PADC(WinStr,80,"░")
  1839.       NEXT
  1840.  
  1841.       SETCOLOR("W+/BG")
  1842.       @ 0,0,24,79 BOX "┌─┐│┘─└│"
  1843.  
  1844.       SETCOLOR("GR+/R,W/R,,,N/W")
  1845.       @ 2,25 SAY "    Customer Contacts    "
  1846.       @ 16,8 SAY "Received: "
  1847.  
  1848.       SETCOLOR("GR+/RB,N/BG,,,N/W")
  1849.       @ 9,49 SAY "Importance "
  1850.       @ 5,15 SAY "Short ID "
  1851.       @ 7,14 SAY "Firstname "
  1852.       @ 8,16 SAY "Surname "
  1853.       @ 10,18 SAY "Title "
  1854.       @ 12,14 SAY "Call Rate "
  1855.       @ 14,14 SAY "Interests "
  1856.       @ 16,21 SAY "Xmas Card? "
  1857.       @ 16,37 SAY "XMas Gift? "
  1858.       @ 16,53 SAY "Golf Day Invite? "
  1859.       @ 19,12 SAY "Note: "
  1860.      DO GETSCR2
  1861.      DO MENU2
  1862.  
  1863.  RETURN
  1864.  
  1865.  PROCEDURE GETSCR1
  1866.  
  1867.       @ 4,20 GET aSHORTNAM PICTURE "XXXXXXXXXX"
  1868.       @ 6,20 GET aCOMPANY PICTURE "XXXXXXXXXX"
  1869.       @ 8,20 GET aADDRESS1 PICTURE "XXXXXXXXXX"
  1870.       @ 9,20 GET aADDRESS2 PICTURE "XXXXXXXXXX"
  1871.       @ 10,20 GET aADDRESS3 PICTURE "XXXXXXXXXX"
  1872.       @ 11,20 GET aADDRESS4 PICTURE "XXXXXXXXXX"
  1873.       @ 13,20 GET aPOSTCODE PICTURE "XXXXXXXXXX"
  1874.       @ 15,20 GET aTELNO PICTURE "XXXXXXXXXX"
  1875.       @ 16,20 GET aFAXNO PICTURE "XXXXXXXXXX"
  1876.       @ 18,21 GET aSALEAREA PICTURE "XXXXXXXXXX"
  1877.       @ 20,21 GET aSALESREP PICTURE "XXXXXXXXXX"
  1878.       @ 18,58 GET aCREDIT PICTURE "XXXXXXXXXX"
  1879.       @ 14,58 GET aBUSTYPE PICTURE "XXXXXXXXXX"
  1880.       @ 4,52 GET aACCNO PICTURE "XXXXXXXXXX"
  1881.       @ 16,58 GET aTURNTARG PICTURE "XXXXXXXXXX"
  1882.       @ 20,58 GET aLASTORD PICTURE "@D"
  1883.  
  1884.  RETURN
  1885.  
  1886.  PROCEDURE GETSCR2
  1887.  
  1888.       @ 9,61 GET aIMPORT PICTURE "XXXXXXXXXX"
  1889.       @ 5,25 GET bSHORTID PICTURE "XXXXXXXXXX"
  1890.       @ 7,25 GET bFIRSTNAM PICTURE "XXXXXXXXXX"
  1891.       @ 8,25 GET bSURNAME PICTURE "XXXXXXXXXX"
  1892.       @ 10,25 GET bTITLE PICTURE "XXXXXXXXXX"
  1893.       @ 12,25 GET bCALLRATE PICTURE "XXXXXXXXXX"
  1894.       @ 14,25 GET bINTEREST PICTURE "XXXXXXXXXX"
  1895.       @ 16,33 GET bXMASCARD PICTURE "XXXXXXXXXX"
  1896.       @ 16,49 GET bXMASGIFT PICTURE "XXXXXXXXXX"
  1897.       @ 16,71 GET bGOLFDAY PICTURE "XXXXXXXXXX"
  1898.       @ 19,20 GET bNOTE PICTURE "XXXXXXXXXX"
  1899.  
  1900.  RETURN
  1901.  PROCEDURE DECVARS1
  1902.     PUBLIC aSHORTNAM
  1903.     PUBLIC aCOMPANY
  1904.     PUBLIC aADDRESS1
  1905.     PUBLIC aADDRESS2
  1906.     PUBLIC aADDRESS3
  1907.     PUBLIC aADDRESS4
  1908.     PUBLIC aPOSTCODE
  1909.     PUBLIC aTELNO
  1910.     PUBLIC aFAXNO
  1911.     PUBLIC aSALEAREA
  1912.     PUBLIC aSALESREP
  1913.     PUBLIC aCREDIT
  1914.     PUBLIC aBUSTYPE
  1915.     PUBLIC aACCNO
  1916.     PUBLIC aTURNTARG
  1917.     PUBLIC aLASTORD
  1918.  RETURN
  1919.  
  1920.  
  1921.  PROCEDURE DECVARS2
  1922.     PUBLIC aIMPORT
  1923.     PUBLIC bSHORTID
  1924.     PUBLIC bFIRSTNAM
  1925.     PUBLIC bSURNAME
  1926.     PUBLIC bTITLE
  1927.     PUBLIC bCALLRATE
  1928.     PUBLIC bINTEREST
  1929.     PUBLIC bXMASCARD
  1930.     PUBLIC bXMASGIFT
  1931.     PUBLIC bGOLFDAY
  1932.     PUBLIC bNOTE
  1933.  RETURN
  1934.  
  1935.  
  1936.  PROCEDURE INITVARS1
  1937.    aSHORTNAM = SPACE(10)
  1938.    aCOMPANY = SPACE(30)
  1939.    aADDRESS1 = SPACE(30)
  1940.    aADDRESS2 = SPACE(30)
  1941.    aADDRESS3 = SPACE(30)
  1942.    aADDRESS4 = SPACE(30)
  1943.    aPOSTCODE = SPACE(15)
  1944.    aTELNO = SPACE(15)
  1945.    aFAXNO = SPACE(15)
  1946.    aSALEAREA = SPACE(1)
  1947.    aSALESREP = SPACE(20)
  1948.    aCREDIT = SPACE(9)
  1949.    aBUSTYPE = SPACE(12)
  1950.    aACCNO = SPACE(20)
  1951.    aTURNTARG = SPACE(11)
  1952.    aLASTORD = DATE()
  1953.  RETURN
  1954.  PROCEDURE INITVARS2
  1955.    aIMPORT = SPACE(1)
  1956.    bSHORTID = SPACE(10)
  1957.    bFIRSTNAM = SPACE(20)
  1958.    bSURNAME = SPACE(20)
  1959.    bTITLE = SPACE(20)
  1960.    bCALLRATE = SPACE(10)
  1961.    bINTEREST = SPACE(40)
  1962.    bXMASCARD = SPACE(1)
  1963.    bXMASGIFT = SPACE(1)
  1964.    bGOLFDAY = SPACE(1)
  1965.    bNOTE = SPACE(50)
  1966.  RETURN
  1967.  
  1968.  
  1969.  PROCEDURE SETVARS1
  1970.     aSHORTNAM = a->SHORTNAM
  1971.     aCOMPANY = a->COMPANY
  1972.     aADDRESS1 = a->ADDRESS1
  1973.     aADDRESS2 = a->ADDRESS2
  1974.     aADDRESS3 = a->ADDRESS3
  1975.     aADDRESS4 = a->ADDRESS4
  1976.     aPOSTCODE = a->POSTCODE
  1977.     aTELNO = a->TELNO
  1978.     aFAXNO = a->FAXNO
  1979.     aSALEAREA = a->SALEAREA
  1980.     aSALESREP = a->SALESREP
  1981.     aCREDIT = a->CREDIT
  1982.     aBUSTYPE = a->BUSTYPE
  1983.     aACCNO = a->ACCNO
  1984.     aTURNTARG = a->TURNTARG
  1985.     aLASTORD = a->LASTORD
  1986.  RETURN
  1987.  
  1988.  
  1989.  PROCEDURE SETVARS2
  1990.     aIMPORT = a->IMPORT
  1991.     bSHORTID = b->SHORTID
  1992.     bFIRSTNAM = b->FIRSTNAM
  1993.     bSURNAME = b->SURNAME
  1994.     bTITLE = b->TITLE
  1995.     bCALLRATE = b->CALLRATE
  1996.     bINTEREST = b->INTEREST
  1997.     bXMASCARD = b->XMASCARD
  1998.     bXMASGIFT = b->XMASGIFT
  1999.     bGOLFDAY = b->GOLFDAY
  2000.     bNOTE = b->NOTE
  2001.  RETURN
  2002.  
  2003.  PROCEDURE REPLVARS1
  2004.     REPLACE a->SHORTNAM WITH aSHORTNAM
  2005.     REPLACE a->COMPANY WITH aCOMPANY
  2006.     REPLACE a->ADDRESS1 WITH aADDRESS1
  2007.     REPLACE a->ADDRESS2 WITH aADDRESS2
  2008.     REPLACE a->ADDRESS3 WITH aADDRESS3
  2009.     REPLACE a->ADDRESS4 WITH aADDRESS4
  2010.     REPLACE a->POSTCODE WITH aPOSTCODE
  2011.     REPLACE a->TELNO WITH aTELNO
  2012.     REPLACE a->FAXNO WITH aFAXNO
  2013.     REPLACE a->SALEAREA WITH aSALEAREA
  2014.     REPLACE a->SALESREP WITH aSALESREP
  2015.     REPLACE a->CREDIT WITH aCREDIT
  2016.     REPLACE a->BUSTYPE WITH aBUSTYPE
  2017.     REPLACE a->ACCNO WITH aACCNO
  2018.     REPLACE a->TURNTARG WITH aTURNTARG
  2019.     REPLACE a->LASTORD WITH aLASTORD
  2020.  RETURN
  2021.  
  2022.  
  2023.  PROCEDURE REPLVARS2
  2024.     REPLACE a->IMPORT WITH aIMPORT
  2025.     REPLACE b->SHORTID WITH bSHORTID
  2026.     REPLACE b->FIRSTNAM WITH bFIRSTNAM
  2027.     REPLACE b->SURNAME WITH bSURNAME
  2028.     REPLACE b->TITLE WITH bTITLE
  2029.     REPLACE b->CALLRATE WITH bCALLRATE
  2030.     REPLACE b->INTEREST WITH bINTEREST
  2031.     REPLACE b->XMASCARD WITH bXMASCARD
  2032.     REPLACE b->XMASGIFT WITH bXMASGIFT
  2033.     REPLACE b->GOLFDAY WITH bGOLFDAY
  2034.     REPLACE b->NOTE WITH bNOTE
  2035.  RETURN
  2036.  
  2037.  
  2038.  PROCEDURE RELVARS1
  2039.     RELEASE aSHORTNAM
  2040.     RELEASE aCOMPANY
  2041.     RELEASE aADDRESS1
  2042.     RELEASE aADDRESS2
  2043.     RELEASE aADDRESS3
  2044.     RELEASE aADDRESS4
  2045.     RELEASE aPOSTCODE
  2046.     RELEASE aTELNO
  2047.     RELEASE aFAXNO
  2048.     RELEASE aSALEAREA
  2049.     RELEASE aSALESREP
  2050.     RELEASE aCREDIT
  2051.     RELEASE aBUSTYPE
  2052.     RELEASE aACCNO
  2053.     RELEASE aTURNTARG
  2054.     RELEASE aLASTORD
  2055.  RETURN
  2056.  PROCEDURE RELVARS2
  2057.     RELEASE aIMPORT
  2058.     RELEASE bSHORTID
  2059.     RELEASE bFIRSTNAM
  2060.     RELEASE bSURNAME
  2061.     RELEASE bTITLE
  2062.     RELEASE bCALLRATE
  2063.     RELEASE bINTEREST
  2064.     RELEASE bXMASCARD
  2065.     RELEASE bXMASGIFT
  2066.     RELEASE bGOLFDAY
  2067.     RELEASE bNOTE
  2068.  RETURN
  2069.  
  2070.  
  2071.  PROCEDURE DUMMY
  2072.  RETURN
  2073.  
  2074.  
  2075.  PROCEDURE MENU1
  2076.   LOCAL MKey
  2077.  
  2078.       SET ESCAPE OFF
  2079.         SETCOLOR("R/W,W/R,,,N/W")
  2080.  
  2081.       @ 22,5 PROMPT " ADD  " MESSAGE " "
  2082.       @ 22,14 PROMPT " EDIT " MESSAGE " "
  2083.       @ 22,23 PROMPT "DELETE" MESSAGE " "
  2084.       @ 22,32 PROMPT " NEXT " MESSAGE " "
  2085.       @ 22,41 PROMPT " PREV " MESSAGE " "
  2086.       @ 22,50 PROMPT " FIND " MESSAGE " "
  2087.       @ 22,69 PROMPT " QUIT " MESSAGE " "
  2088.       @ 22,59 PROMPT "CONTACT" MESSAGE " "
  2089.  
  2090.        MENU TO MKey
  2091.        DO MENUCASE1 WITH MKey
  2092.  RETURN
  2093.  
  2094.  PROCEDURE MENU2
  2095.   LOCAL MKey
  2096.  
  2097.       SET ESCAPE OFF
  2098.  
  2099.         SETCOLOR("R/W,W/R,,,N/W")
  2100.       @ 22,9 PROMPT " ADD  " MESSAGE " "
  2101.       @ 22,18 PROMPT " EDIT " MESSAGE " "
  2102.       @ 22,27 PROMPT "DELETE" MESSAGE " "
  2103.       @ 22,36 PROMPT " NEXT " MESSAGE " "
  2104.       @ 22,45 PROMPT " PREV " MESSAGE " "
  2105.       @ 22,54 PROMPT " FIND " MESSAGE " "
  2106.       @ 22,63 PROMPT "RETURN" MESSAGE " "
  2107.        MENU TO MKey
  2108.        DO MENUCASE2 WITH MKey
  2109.  RETURN
  2110.  
  2111.  
  2112.  PROCEDURE MENUCASE1
  2113.    PARAMETER MKey
  2114.     DO CASE
  2115.  
  2116.       CASE MKey = 1
  2117.          DO Dummy
  2118.       CASE MKey = 2
  2119.          DO Dummy
  2120.       CASE MKey = 3
  2121.          DO Dummy
  2122.       CASE MKey = 4
  2123.          DO Dummy
  2124.       CASE MKey = 5
  2125.          DO Dummy
  2126.       CASE MKey = 6
  2127.          DO Dummy
  2128.       CASE MKey = 7
  2129.          DO Dummy
  2130.       CASE MKey = 8
  2131.          DO Dummy
  2132.  
  2133.      ENDCASE
  2134.  RETURN
  2135.  PROCEDURE MENUCASE2
  2136.    PARAMETER MKey
  2137.     DO CASE
  2138.  
  2139.       CASE MKey = 1
  2140.          DO Dummy
  2141.       CASE MKey = 2
  2142.          DO Dummy
  2143.       CASE MKey = 3
  2144.          DO Dummy
  2145.       CASE MKey = 4
  2146.          DO Dummy
  2147.       CASE MKey = 5
  2148.          DO Dummy
  2149.       CASE MKey = 6
  2150.          DO Dummy
  2151.       CASE MKey = 7
  2152.          DO Dummy
  2153.  
  2154.      ENDCASE
  2155.  RETURN
  2156.  
  2157.  
  2158. Note: you may use this program by adding a few lines of code to
  2159.       it. If you place "DO SCREEN1" before the declaration of
  2160.       procedure SCREEN1 and you add "USE COMPANY" and "USE
  2161.       CONTACT" after the local variable declarations, then
  2162.       compile the program, you will be able to see the data entry
  2163.       screen as it would appear in a Clipper program. You will of
  2164.       course need to add SET RELATION or similar commands to
  2165.       relate the fields in the two database files, and if you
  2166.       intend to use the program on a network you will need to
  2167.       open your files accordingly. You will need to add the code
  2168.       to add, edit and delete records. SLD should greatly reduce
  2169.       the time taken to produce screens and menus. Our further
  2170.       planned releases will do even more for you.
  2171.  
  2172. Test programs are also generated at the same time as you generate
  2173. the main code .PRG. These test programs can be used to test the
  2174. operation of the main code: 
  2175.  
  2176. For Clipper:      CLIPTEST.PRG for Clipper code. Compile and link
  2177.                   the generated code with the CLIPMAKE.BAT batch
  2178.                   file (also generated at the SAME TIME).
  2179.             
  2180. For dBase:        DBTEST.PRG for dBase code. Run this program
  2181.                   from the applications generator.
  2182.  
  2183. How To Complete Your Application.
  2184. ---------------------------------
  2185. Whilst Screen Layout Designer takes care of the bulk of the task
  2186. of generating source code you will need to open your data files,
  2187. take care of database file relations, record locking and general
  2188. record operations. SLD was designed to take the hit and miss
  2189. frustration out of data entry screen layout and menu design, but
  2190. not to replace the programmer. (Please note: future versions SLD
  2191. will be able to open data files, take care of relational code and
  2192. record locking, and more).
  2193.  
  2194.  
  2195.                        Appendix C.
  2196.                        ===========
  2197.  
  2198. Two Tutorials.
  2199. --------------------
  2200. Here are two examples of how to read input from two previously
  2201. created input files.  The first example demonstrates how to get
  2202. SLD to read directly from a database file, COMPANY.DBF, and the
  2203. second example demonstrates how to read fields from a previously
  2204. created Screen Layout File, SCREEN.SLF or TUTOR1.SLF.  You will
  2205. be shown how to generate the code in the form of a .PRG file and
  2206. view it with an editor.
  2207.  
  2208. Tutorial One: Direct from a .DBF
  2209. ------------------------------
  2210. Action 1:  Start SLD.
  2211. Action 2:  select Setup from the Main Menu bar, followed by
  2212.             InputType.
  2213. Action 3: select Direct (the system is set to read directly from
  2214.             a .DBF)
  2215. Action 4:  press Esc until you return to the Main Menu bar.
  2216. Action 5:  select File, followed by Input.
  2217. Action 6:  select DBase.
  2218. Action 7:  enter "COMPANY" in the box next to the DB File 1
  2219.             prompt and ensure that all other boxes are empty.
  2220. Action 8:  press Ctrl and Enter.
  2221. Action 9:  select Text.
  2222. Action 10: enter the name of the intermediate text file, eg.
  2223.             TUTOR1.TXT
  2224. Action 11: press Esc until you return to the Main Menu bar.
  2225. Action 12: select SHOW  (if the file TUTOR1.TXT exists you will
  2226.             be prompted to overwrite it, so enter "Y" in this
  2227.             case)
  2228. Action 13: you will now be in the Screen Edit Menu. Select
  2229.             ScreenEdit, or alternatively press  the Esc key.
  2230. Action 14: you will now be in Screen Edit Mode, so, either use
  2231.             a mouse or the arrow keys to move the cursor onto a
  2232.             data field displayed on the screen.
  2233. Action 15: with the cursor on a data field, or its heading, click
  2234.             with the left mouse button or press the Enter key.
  2235. Action 16: you may now move the field around the screen.
  2236. Action 17: when you are satisfied with the position of the field
  2237.             on the screen click with the left mouse button or
  2238.             press Enter.
  2239. Action 18: to see information about the contents of the field,
  2240.             ensure that the cursor is over the field or its
  2241.             heading and double the left mouse button quickly or
  2242.             press F2.
  2243. Action 19: you may edit the heading text or change the screen on
  2244.             which it will be displayed. For the moment move down
  2245.             to the Field Description prompt and change the text.
  2246. Action 20: Press Ctrl and Enter to save the text. The field
  2247.             heading will change accordingly. Adding a box:
  2248.  
  2249. Action 21: Press Esc to return to the Screen Edit Menu bar.
  2250. Action 22: select Box.
  2251. Action 23: select New. You will enter Box Edit Mode.
  2252. Action 24: move the cursor around the screen to the position
  2253.             where you want the box to start.
  2254. Action 25: click with the left mouse button or press enter.
  2255. Action 26: when you move the cursor with the mouse or arrow keys
  2256.             the box will expand or contract from its origin.
  2257. Action 27: Press F3. Now when you move the cursor the box will
  2258.             remain the same size, but will move around the
  2259.             screen.
  2260. Action 28: press F3 again. The box will expand or contract when
  2261.             you move the cursor again.
  2262. Action 29: When you are happy with the size and position of the
  2263.             box press the Enter key or click the left mouse
  2264.             button. You have succeeded in drawing a box! 
  2265.  
  2266. Adding a Title:
  2267.  
  2268. Action 30: Press Esc to return to the Screen Edit Menu bar.
  2269. Action 31: Select Title.
  2270. Action 32: select New.
  2271. Action 33: you will be prompted to enter some text for your
  2272.             title. Do so and press Enter. You will enter Title
  2273.             Edit Mode.
  2274. Action 34: Move the cursor to where you want the title to begin, 
  2275.             then click with the left mouse button or press Enter.
  2276. Action 35: when you move the cursor the title will expand or
  2277.             contract.
  2278. Action 36: press F3. Now when you move the cursor the title will
  2279.             move.
  2280. Action 37: press F3 again. You will be able to expand/ contract
  2281.             and move the title.
  2282. Action 38: when you are satisfied with the position and size of
  2283.             your title press Enter, or click the left mouse
  2284.             button. You have drawn a title.
  2285.  
  2286. Adding a User defined Menu:
  2287. Action 39: Press Esc to return to the Screen Edit Menu bar.
  2288. Action 40: Select Menu.
  2289. Action 41: select Add. You have now added a new menu system to
  2290.             the screen on view.
  2291. Action 42: select New. This will add a new menu option to the new
  2292.             menu.
  2293. Action 43: you will be prompted to enter a heading text for your
  2294.             menu option (eg. "EDIT"). Do so and press Enter. You
  2295.             will enter Menu Edit Mode.
  2296. Action 44: Move the cursor to where you want the menu option to
  2297.             begin, then click with the left mouse button or press
  2298.             Enter. Action 45: when you move the cursor the menu option will expand
  2299.             or contract.
  2300. Action 46: press F3. Now when you move the cursor the menu option
  2301.             will move.
  2302. Action 47: press F3 again. You will be able to expand/ contract
  2303.             and move the menu option.
  2304. Action 48: when you are satisfied with the position and size of
  2305.             your menu option press Enter, or click the left mouse
  2306.             button.
  2307.  
  2308. You have drawn the first option on your new menu.(You may repeat
  2309. steps 42 to 48 if you want to continue adding options to your new
  2310. menu, or continue to 48).
  2311.  
  2312.  
  2313. Generating the Code:
  2314.  
  2315. Action 49: Press Esc to return to the Screen Edit Menu bar.
  2316. Action 50: Select Quit. You will be returned to the Main Menu.
  2317. Action 51: from the Main Menu select File, followed by Output,
  2318.             then Code.
  2319. Action 52: enter the name of the source code output file, eg.
  2320.             TUTOR1.PRG
  2321. Action 53: press Esc until you return to the top level of the
  2322.             Main Menu.
  2323. Action 54: select Generate, followed by Code.
  2324. Action 55: if the TUTOR1.PRG or other file exists you will be
  2325.             warned. In this case enter "Y" to overwrite it. The
  2326.             screen code will be generated.
  2327.  
  2328. Viewing the generated Code:
  2329.  
  2330. Action 56: select Edit, followed by Output from the Main Menu
  2331.             bar.
  2332. Action 57: enter the name of your output code file, eg.
  2333.             TUTOR1.PRG (or press Enter if it is shown). Your
  2334.             output source code wil be displayed.
  2335. Action 58: To exit the editor, press F4.
  2336.  
  2337. Saving Your Work:
  2338.  
  2339. Action 59: pres Esc to return to the top level of the Main Menu
  2340.             bar.
  2341. Action 60: select File, followed by Output, then SLF.
  2342. Action 61: enter the name of a Screen Layout File, eg. TUTOR1.SLF
  2343. Action 62: Esc to the Main Menu bar.
  2344. Action 63: select Generate, followed by SLF.
  2345. Action 64: if the file TUTOR1.SLF, etc. exists then enter "Y" to
  2346.             the prompt to overwrite it.
  2347.  
  2348. To exit SLD:
  2349.  
  2350. Action 65: Select Exit (or just press Esc) from the Main Menu
  2351.             bar. You will be prompted to confirm whether you wish
  2352.             to exit, and whether to save setup and screen
  2353.             information. For the moment respond "Y" to confirm
  2354.             that you want to exit and "N" to save setup/screen
  2355.             information.
  2356.  
  2357. Well done, you have generated your first application!
  2358.  
  2359. Tutorial Two: Reading from an SLF:
  2360. ----------------------------------
  2361. Action 1:  Start SLD.
  2362. Action 2:  select Setup from the Main Menu, then InputType from 
  2363.             the Setup Menu.
  2364. Action 3:  select SLF (the system is set to read from a
  2365.             previously generated Screen Layout File).
  2366. Action 4:  press Esc until you return to the Main Menu bar.
  2367. Action 5:  select File, followed by Input.
  2368. Action 6:  select SLF.
  2369. Action 7:  enter the name of a previously generated SL File in
  2370.             the box,  eg. TUTOR1.SLF that you generated in
  2371.             Tutorial One.
  2372. Action 8:  press Enter.
  2373. Action 9:  press Esc until you return to the Main menu bar.
  2374. Action 10: select SHOW.
  2375. Action 11: you will now be in the Screen Edit Menu. Select
  2376.             ScreenEdit, or alternatively press  the Esc key.
  2377. Action 12: the data fields from the SLF will be displayed and
  2378.             your screen and you will enter Screen Edit Mode.
  2379.  
  2380. You may now proceed according to the Actions from 14 onwards in 
  2381. Tutorial 1.
  2382.                         Appendix D.
  2383.                         ===========
  2384.  
  2385. FUTURE ENHANCEMENTS OF THE SCREEN LAYOUT DESIGNER.
  2386. --------------------------------------------------
  2387.  
  2388. Development is continuing on this software and related products
  2389. too.  Of course we would appreciate your interest and feedback. 
  2390. By listening to users of this software we can provide you with
  2391. what you want. In addition to planned enhancements to this
  2392. program we are developing one related program in particular:
  2393.  
  2394. A separate program, as part of a suite of software, for creating
  2395. .DBF files and for defining relational links between files,
  2396. including definition of primary and foreign keys, which will be
  2397. used by SLD to generate complete relational database
  2398. applications, including network record and file locking for
  2399. multi-user environments. This will reduce greatly the programming
  2400. work required by the developer. Work on this is in progress at
  2401. present. This will complement SLD  and registered users of SLD
  2402. will geat a generous discount on this software when available.
  2403.  
  2404. We also intend to produce further modules for SLD so that it can
  2405. generate screen source code in other languages.
  2406.  
  2407. We are investigating the feasibility of a separate program
  2408. allowing users not developing in dBase generic code to use SLD to
  2409. generate data entry screen source code in other languages. This
  2410. would allow users to define their own procedures or functions for
  2411. generating an object on the screen. SLD would use the defined
  2412. functions/procedures to generate screen source code.
  2413.  
  2414.  
  2415.  
  2416.  
  2417.                         Appendix E.
  2418.                         ===========
  2419.  
  2420. TECHNICAL SUPPORT
  2421. =================
  2422.  
  2423. If you have any technical problems with Screen Layout Designer,
  2424. or you wish to enquire about other software we are developing,
  2425. then youshould contact us at the address below, or telephone
  2426. 0703-701936 in the UK or 44 703 701936 outside the UK. Another
  2427. number you may call at weekends if you are unable to contact us
  2428. is 0329 833488 in the UK, or 44 329 833488 outside the UK. 
  2429.  
  2430. Compuserve support is available: user id: 100116,370 
  2431.  
  2432.       Neville T. Palmer
  2433.       PDM Associates
  2434.       17 Heathlands
  2435.       Shedfield
  2436.       Southampton
  2437.       Hants
  2438.       SO3 2JD
  2439.       England
  2440.  
  2441.  
  2442. Who are PDM Associates?:
  2443. We are a group of three programmers who have been working
  2444. together since 1991 on various projects. We will continue to work
  2445. in this way in the future. 
  2446.                         REGISTRATION.
  2447.                         =============
  2448. If you register your copy of Screen Layout Designer we will send
  2449. you the latest version of the software, which will include any
  2450. enhancements. The cost of registration is US $40 or £25 Sterling. 
  2451. To register, please print and fill in the form below,
  2452. then send it, together with the appropriate payment, made out to
  2453. Neville T. Palmer, to this address:
  2454.  
  2455.       Neville T. Palmer
  2456.       PDM Associates
  2457.       17 Heathlands
  2458.       Shedfield
  2459.       Southampton
  2460.       Hants
  2461.       SO3 2JD
  2462.       England
  2463.       
  2464. Registration Form - Screen Layout Designer V1.03 Plus
  2465. -----------------------------------------------------
  2466.  
  2467.       Name:    ____________________________________
  2468.  
  2469.       Company: ____________________________________
  2470.  
  2471.       Address: ____________________________________
  2472.  
  2473.                ____________________________________
  2474.       
  2475.       City:    _____________________
  2476.  
  2477.       State/County:  _______________    
  2478.       
  2479.       Zip/Post Code: _______________
  2480.  
  2481.       Country:       _______________
  2482.  
  2483.       Telephone: __________________  Fax:__________________
  2484.  
  2485.       Compuserve: _________________
  2486.  
  2487.       IMPORTANT!! Please enter the Name that you wish to appearon
  2488.       your registration screen when running the program (14 to 40
  2489.       alphanumeric characters; see next page for full info):
  2490.  
  2491.       Registered Name:
  2492.       
  2493.       ______________________________________________________
  2494.  
  2495.       Disk Size for Update(s):  5.25" [ ]      3.25" [ ]
  2496.  
  2497.       Please enclose $40 US or £25 Sterling (or equivalent)
  2498. HOW TO COMPLETE PROGRAM REGISTRATION:
  2499. ------------------------------------
  2500.  
  2501. To register you should send us the appropriate fee along with the
  2502. name that you will register this software under. This name must
  2503. consist of at least 14 alphamumeric characters. Valid characters
  2504. are capital 'A' to 'Z', lower case 'a' to 'z', number '0' to '9'
  2505. and figures &',/()-   (ampersand, apostrophe, comma, forward
  2506. slash, left bracket, right bracket and hyphen). Spaces are of
  2507. course permitted between words, but note that there must be at
  2508. least 11 non-space characters in the name. No other characters
  2509. are valid. Case sensitivity is not important. When we receive the
  2510. registration fee and name we will generate a registration number
  2511. encoded from the name, so it is important that you send us the
  2512. exact name you will use for registration. We will send you the
  2513. latest version of this software. You will also be entitled to
  2514. full support and discounts on our other programs. We will send
  2515. you the registration number and confirmation of the name. You
  2516. should then run SLD and go into the Setup Menu from the main
  2517. menu, then select "OTHER", followed by "REGISTER" from this menu.
  2518. From here enter the name and registration number.  When you have
  2519. entered them satisfactorily.  Press the F2 function key to to
  2520. complete registration. You will see a message telling you that
  2521. registration has been successful. If you see an error message
  2522. "invalid registration number" then check that you have entered
  2523. the name and number correctly. 
  2524.  
  2525. The registration number and name are stored in a text file called
  2526. 'REGISTER.SLD'. This file must be present in the directory from
  2527. which you run SLD otherwise the registration information will not
  2528. be picked up by the program. You can generate this file in more
  2529. than one directory. Keep your registration number and name safe
  2530. so that if you accidentally delete this file you can re-generate
  2531. it.
  2532.  
  2533. When you complete registration the delay on the message at the
  2534. start and end of the program will be removed. You will only see
  2535. the opening screen with your rgistered name on it and you may
  2536. press any key or click a mouse button to continue immediately.
  2537.  
  2538.  
  2539. RESTRICTIONS
  2540. ------------
  2541. Your registration entitles you to use this software on a single
  2542. computer and make a copy for backup purposes. If you intend to
  2543. use this software on more than one computer then you should
  2544. register each copy.
  2545.  
  2546. If you are reading this text at registration time then thankyou
  2547. for your support.
  2548.                   SOFTWARE FOR YOU!
  2549.                   =================
  2550.  
  2551. This software has been aimed at professional and amateur software
  2552. developers and dealers with experience ranging from novice to
  2553. advanced. We always welcome any comments regarding our software
  2554. so that we can write software that people want. The whole purpose
  2555. of this software is to make life easier for you!
  2556.  
  2557. Additionally we may be able to customise this product for your
  2558. individual requirements. Contact us today.
  2559.  
  2560. We are also working on other developement/database projects.
  2561. Details upon request!
  2562.  
  2563. Screen Layout Designer V1.03d
  2564. -----------------------------
  2565.  
  2566. The Differences Between Version 1.03 and 1.03c.
  2567. ------------------------------------------------
  2568. Improvements have been made in the way SLD selects the
  2569. text mode. Three modes are supported: 25 rows x 80 columns,
  2570. 43 x 80 and 50 x 80. The improvements are as follows:
  2571.  
  2572. 1) improvements to overcome text mode selection problems
  2573.    experienced on some PCs.
  2574.  
  2575. 2) use of the DOS 4 & 5 MODE command to allow EGA emulation
  2576.    on a VGA display.
  2577.  
  2578. 3) Allow Clipper to use 50 line mode.
  2579.  
  2580. 4) User may select a display adapter type (MDA, CGA, EGA, VGA).
  2581.  
  2582. 5) Changes to the SETUPS.SET file and Screen Layout
  2583.    Files (SLF), so that mode and display type are saved,
  2584.    etc.
  2585.  
  2586. 6) dBase III and IV users now have the choice of 3 menu           
  2587.    types:
  2588.       i) Clipper style menus.
  2589.       ii) conventional dBase menus with the choice input in
  2590.           an @GET.
  2591.       iii) conventional dBase menus with no @GET.
  2592.  
  2593. 7) Frame types can be reset globally to a new type.
  2594.  
  2595. 8) dBase IV frame strings are now correct.
  2596.  
  2597. 9) Corrections and amendments to documentation.
  2598.  
  2599. 10)   Generated source code files now have a header describing
  2600.       the file name, date, author and registration name.
  2601.  
  2602. 11)  Mouse speed option added to Setup Menu. 5 mouse speeds.
  2603. 12)  DBFs may be correctly selected from alternative directory.