home *** CD-ROM | disk | FTP | other *** search
/ Enter 1998 December / ENTER12_1.iso / Dema / pwrproj / TUTORIAL.LIB / BORDER.TXT < prev   
Encoding:
Text File  |  1997-02-19  |  43.6 KB  |  1,019 lines

  1. Welcome to the Border manual. 
  2.  
  3. Please turn word wrap on in your text file viewer so that the line length in this document is adjusted to the current window size.
  4.  
  5. The Help file supplied with Border contains much of the information in this document and includes a full list of the tokens available for use with PowerProject. To open the Border Help, run Border and press F1.
  6.  
  7. CONTENTS OF THIS DOCUMENT
  8.  
  9. Chapter 1: Getting started with Border
  10. Installation
  11. Creating a simple border
  12.  
  13. Chapter 2: Using Border
  14. When to use Border
  15. Starting Border
  16. How to use Border
  17.  
  18. Chapter 3: Border script commands
  19. Compulsory commands
  20. Border script syntax
  21. List of commands
  22. Summary of commands
  23.  
  24.  
  25. Chapter 1: Getting started with Border
  26. ======================================
  27. Border is a separate program supplied with PowerProject. You use it to design borders to frame PowerProject graphics for output. Several sample borders are supplied with PowerProject. You can use these borders as they are, or tailor them to your specific requirements.
  28.  
  29. Each border file is made up of Border Script commands, which describe the text, boxes, lines and pictures in the border.
  30.  
  31. This chapter teaches you the basics of using Border. It assumes that you have worked through the lessons in the PowerProject Concepts & Learning manual and are familiar with opening projects, starting new projects and printing from PowerProject.
  32.  
  33.  
  34. Installation
  35. -------------
  36. Border is installed as part of the PowerProject installation procedure. Refer to your PowerProject Getting Started manual for details of how to install PowerProject and Border on your computer. You will need to install PowerProject and Border before you can work through the steps in this chapter.
  37.  
  38.  
  39. Creating a simple border
  40. ------------------------
  41. Start Border by selecting it from the Windows 95 Start menu or by double-clicking on its program icon in the Windows 3.x Program Manager. After a few moments the two main Border windows will be displayed.
  42.  
  43. A border is created using script commands which you type into the script window on the left of the screen. The border resulting from the commands is displayed in the border window on the right of the screen.
  44.  
  45. Each border must include two compulsory commands. You will create a simple border including these commands.
  46.  
  47. The cursor should be at the top left of the window, and the line at the top of the window should read Line 1 Column 1.
  48.  
  49. 1. Type the following line:
  50.  
  51.     UNITSIZE    254
  52.  
  53. The first word on each line is the command, and the information which follows it is called the argument. Press TAB to separate the command from the argument, so your script is easier to read. You can type in CAPITALS or lower case. This command has set the current unit of measurement to inches. If you do not use this command, the current unit of measurement will be millimeters.
  54.  
  55. 2. Press ENTER at the end of the line to start a new line. On the new line, type:
  56.  
  57.     STYLE    A 8.5 x 11"
  58.  
  59. The style command is a compulsory command. It sets the name that is displayed in PowerProject when you load the border file.
  60.  
  61. 3. Press ENTER at the end of the line to start a new line. On the new line, type:
  62.  
  63.     PAGESIZE    LETTER, PORTRAIT
  64.  
  65. This is the second compulsory command. A standard page size and orientation follows the pagesize command.
  66.  
  67. Using a standard page size, Border always gives a 10 mm (0.4 inch) margin all around the paper. If you want to use a page size with no margins, you must create a custom page size and specify the width and height dimensions. For example, for Letter, portrait orientation with no margin, you would use: PAGESIZE    CUSTOM,15/2, 11
  68.  
  69. Now you will set the area of the page in which the chart will be printed.
  70.  
  71. 4. Press ENTER at the end of the line, then type the following two lines:
  72.  
  73.     MOVETO    0,1 
  74.     CHARTAREA    WIDTH-0, HEIGHT-0
  75.  
  76. The MOVETO command sets the coordinates of the start of the following item which is the chart area. The first value is the X position and the second value is the Y position. In this example, the chart area starts from the left-hand margin and 1inch down from the top margin.
  77.  
  78. The chartarea command sets the extents of the chart area. Since both the width and height have been set to 0, the chart area will extand to the bottom right-hand corner of the page. The CHARTAREA command is not compulsory, but you must include it to use the border with a PowerProject chart.
  79.  
  80. Note that:
  81. * WIDTH is the distance between left and right page margins
  82. * HEIGHT is the distance between the top and bottom page margins.
  83.  
  84. 5. Press ENTER at the end of the chartarea command line. Your script should now contain the following lines:
  85.  
  86.     UNITSIZE    254 
  87.     STYLE    A 8.5 x 11 
  88.     PAGESIZE    LETTER, PORTRAIT 
  89.     MOVETO    0,1 
  90.     CHARTAREA    WIDTH-0, HEIGHT-0
  91.  
  92. 6. Choose Execute from the Options menu. Border now checks that you have included the compulsory commands and that the lines you have typed are correct.
  93.  
  94. Provided the script is correct, the border window should display a rectangle containing a representation of the chart. There should be a blank area across the top of the chart. Later you will edit the border so that the project title and a graphic are displayed in this area.
  95.  
  96. If any errors were found in the script, an error window will be displayed at the bottom of the screen. A message in the error window tells you which line has an error. You can ALT click on the error message line to go straight to the script window at the beginning of the line containing the error. Correct the line then execute the script again.
  97.  
  98. Saving the script
  99. -----------------
  100. At the moment, your script is called UNTITLED. You must save it as a border file before it can be used with PowerProject. Save your script now:
  101.  
  102. 1. Select Save As from the File menu. The file selector appears.
  103.  
  104. 2. Open your PowerProject directory (C:\WINDOWS\POWPROJ by default).
  105.  
  106. 3. Enter the filename LESSON. All borders are given the *.B file extension by default.
  107.  
  108. 4. Click on OK to close the file selector, saving the border.
  109.  
  110. The name you have entered is displayed at the top of the script window.
  111.  
  112. Before using this border with a chart in PowerProject, we will add some comments to the script.
  113.  
  114. Adding comments to the script
  115. -----------------------------
  116. Comments in a script are useful to remind you what each section or particular line of the script is doing. In a short script you can probably tell what each line does but as your script grows, comments make it much easier to understand and amend.
  117.  
  118. To add comments to your border script:
  119.  
  120. 1. Move the cursor to line 1, column 1 and press ENTER to insert a blank line.
  121.  
  122. 2. Type:
  123.  
  124.     //unitsize 254 sets units to inches
  125.  
  126. Anything after the // will be ignored by Border, so this whole line is a comment.
  127.  
  128. 3. Move the cursor to the end of the CHARTAREA command and type:
  129.  
  130.     //extends to bottom right-hand corner
  131.  
  132. Here you have added a comment to the end of a command line. As you type, the script window scrolls horizontally to keep the cursor in view.
  133.  
  134. 4. When you have finished typing the comment, press HOME to move the cursor back to the start of that line.
  135.  
  136. 5. Select Execute from the Options menu to execute the script again with your comments. Notice that the chart representation does not change because comments do not affect the appearance of a border.
  137.  
  138. 6. When the script has been executed, save your changes to it by selecting Save from the File menu.
  139.  
  140. Adding tokens and graphics
  141. --------------------------
  142. Now you will learn how to include project information and graphics in a border:
  143.  
  144. 1. Click on the line below the chartarea command, then type
  145.  
  146.     MOVETO    1/4,1/2
  147.  
  148. This sets the coordinates for the next item as being one quarter of an inch in from the left margin, and half an inch from the top margin page.
  149.  
  150. 2. Add the following line below the MOVETO command:
  151.  
  152.     TEXTSIZE    1/2
  153.  
  154. This sets the size of the text that follows to be half an inch, or 36 points.
  155.  
  156. 3. Below the TEXTSIZE command, add the following line:
  157.  
  158.     WRITE    "<PROJ-TITLE>"
  159.  
  160. This inserts the token representing the project title at the coordinates given in the MOVETO command and at the size given in the TEXTSIZE command. You can insert many pieces of project information into border files. A full list of the tokens available is given in the Border Help.
  161.  
  162. 4. Press ENTER at the end of the write command line. (If you do not insert a blank line at the end of a script, an error will be reported when you execute the script.)
  163.  
  164. 5. Select Execute from the Options menu to update the border. Notice that <PROJ-TITLE> now appears in the top left-hand corner of the border. When you load this border into PowerProject, <PROJ-TITLE> will be replaced by the title of the active project. You will see how to load borders into PowerProject later.
  165.  
  166. 6. Now add the following MOVETO command to set the start coordinates of the graphic that you will include in the border:
  167.  
  168.     MOVETO    5,1/4
  169.  
  170. This specifies that the graphic starts five inches from the left-hand margin and one quarter of an inch from the top margin.
  171.  
  172. 7. Add this final line below the MOVETO command:
  173.  
  174.     PICTURE    "ACME.WMF",7,1
  175.  
  176. This command specifies the graphic that you want to load in the border and the coordinates at which it ends. You can see that the graphic will be 2 inches wide and three quarters of an inch high.
  177.  
  178. ACME.WMF should be in your PowerProject directory which is also where the Border program should be. If ACME.WMF and the Border program are not in the same directory, you should enter the full pathname of the graphic in the command above, e.g.:
  179.  
  180. PICTURE    C:\WINDOWS\POWPROJ\ACME.WMF
  181.  
  182. 8. Press ENTER at the end of the picture command line to insert an empty line at the end of the script.
  183.  
  184. 9. Select Execute from the Options menu and notice that a graphic is now included in the top right-hand corner of the border.
  185.  
  186. 10. Save the changes to your border by selecting Save from the File menu.
  187.  
  188. If the graphic does not appear, locate ACME.WMF on your hard disk (it should be in your PowerProject directory) and enter its full pathname in the picture command, then execute the border again.
  189.  
  190. Using the border in PowerProject
  191. --------------------------------
  192. Once you have saved your border, you can use it in PowerProject. This section outlines the steps involved in loading the border into PowerProject:
  193.  
  194. 1. Run PowerProject.
  195.  
  196. 2. Open a project if you have one available, or start a new project and draw a few bars on the chart.
  197.  
  198. 3. Select Print Graphics from the File menu to display the tabbed Print dialog.
  199.  
  200. 4. On the Output tab, choose a printer from the drop-down list box in the Output to group box and ensure that the box alongside the list box is checked.
  201.  
  202. 5. Click on the Printer Setup button and ensure that Letter paper size is selected, then return to the Print dialog.
  203.  
  204. 6. On the Border tab, click on the Browse Border button to locate the border you have saved.
  205.  
  206. 7. Using the file selector that appears, select the border that you have saved then OK the file selector to return to the Print dialog.
  207.  
  208. 8. Choose the scaling option you want. In this example, we chose Use Border Without Scaling so that the border fills a sheet of Letter.
  209.  
  210. 9. Click on the Print button to send the chart to the current printer.
  211.  
  212. On the printed chart, youll see that the chart occupies most of the page, with the project title in the left-hand corner and the graphic in the right-hand corner. If your project does not have a title, the word UNTITLED will appear in the position of the project title.
  213.  
  214. The following chapter provides more information about using Border. For details of a specific border script command, refer to Chapter 3 or Borders Help.
  215.  
  216.  
  217. Chapter 2: Using Border
  218. =======================
  219. This chapter explains how to use the Border program. For information about a specific border script command, refer to Chapter 3: Border script commands.
  220.  
  221. When to use Border
  222. ------------------
  223. If you have a suitable border (saved as a .B file) you can select it from PowerProjects Print Graphics dialog as the frame for your graphic. The graphic and its border can then be printed.
  224.  
  225. If you do not want to make any changes to a border, you do not need to use the Border program. To use an existing border to frame a PowerProject graphic, see File Print Graphics in the PowerProject Reference manual.
  226.  
  227. If you want to make changes, or create a new border, you must use Border.
  228.  
  229. Starting Border
  230. ---------------
  231. Start Border in the same way as any other Windows program: by selecting it from the Start menu of Windows 95, or by doubleclicking on the Border icon in the PowerProject program group on your Windows 3.x desktop.
  232.  
  233. Border uses three windows. When you start Border all windows are empty. When you open a border file:
  234. * the appearance of the border is shown in the border window
  235. * the Border Script which creates the border is displayed in the script window
  236. * any errors are shown in the error window.
  237.  
  238. Border window
  239. -------------
  240. The border window is a graphical window. The appearance of the border in this window is not quite the same as it is when you print the border chart from PowerProject:
  241. * the chartarea (the area which is reserved for your chart) is filled with tasks representing your chart, if there are no errors
  242. * the tokens you have included from PowerProject are displayed, not substituted by the data they represent
  243. * the picture contained in the WMF file specified in any Picture command is not shown. Instead, the box displays the name of the WMF file.
  244.  
  245. How to use Border
  246. -----------------
  247. This section provides instructions on how to make changes to a border, include PowerProject details in a border, and how to create a new border. For step by step instructions on how to use Border, work through the lesson in Chapter 1:Getting started with Border.
  248.  
  249. Making changes to a border
  250. --------------------------
  251. There are several sample borders supplied with PowerProject. You can modify these borders to tailor them more precisely to your own needs, for example to include particular project information or to print to a particular output device (i.e. printer or plotter). By modifying these sample borders you can quickly build up a library of borders for your charts.
  252.  
  253. If you intend to modify a border, always make a copy of the border and edit the copy, leaving the original border unchanged for future use. You can copy a file in Windows or simply by opening a border file in Border and saving it under a new name using the File Save As command.
  254.  
  255. Rather than remove a command line from a border script, you can comment it out by preceding it with // to make the command line inactive. When you have edited a border script, use the Execute command in the Options menu to check the script and display an image of the updated border in the border window. Remember to save the changes you make to a border by using the Save command in the File menu.
  256.  
  257. See Editing in the script window and Dealing with error messages for hints which are useful when you change an existing script.
  258.  
  259. Dealing with error messages
  260. ---------------------------
  261. If a border script contains any errors, they will be displayed whenever you open or execute the border. Errors are listed in the error window which is displayed along the bottom of the Border program window. If you close the error window, you can reopen it using the View Errors command in the Window menu.
  262.  
  263. If a border script does not contain any errors, then the error window cannot be displayed.
  264.  
  265. Moving to the error line
  266. ------------------------
  267. You can move from the error window directly to an error line in the script window, using any of the following techniques:
  268. * select the Goto Line command from the Options menu and enter the number of the line containing the error on the Goto Line dialog
  269. * press CTRL G to display the Goto Line dialog, then enter the number of the line containing the error (as above)
  270. *with the error window active, position the pointer anywhere over an error message you want to deal with, then ALT click
  271. *while in the script window you can use the CTRL N shortcut to move to the next error line, and the CTRL P shortcut to move to the previous error line.
  272.  
  273. When you use any of these techniques, the script window becomes active, and the cursor is positioned at the start of the line containing the error.
  274.  
  275. The top line of the script window shows the error message from the error window instead of the normal cursor location display.
  276.  
  277. Including PowerProject details in a border
  278. ------------------------------------------
  279. You can include many PowerProject chart and project details in a border. You do this by choosing the token which represents the information you want, and including it your script using a write command. For example to print the Project title in a border, you would use the command with the token as follows:
  280.  
  281.     WRITE     "<PROJ-TITLE>"
  282.  
  283. You must enclose the token in both double quotes and angle brackets, as shown.
  284.  
  285. The tokens available are listed in Chapter 3: Border script commands, and in the Help. The tokens are listed with the maximum number of characters for each token and the information they represent.
  286.  
  287. Editing in the script window
  288. ----------------------------
  289. You can edit lines in the script window in the same way that you would edit a text file in the Windows Notepad accessory. For example:
  290. * use the arrow keys to move up, down and across lines
  291. * press ENTER or RETURN to create a new line
  292. * use BACKSPACE to delete characters to the left of the cursor
  293. * use DELETE to delete characters to the right of the cursor
  294. * use TAB or spaces to separate the argument from the command section of each line.
  295.  
  296. A list of the keys you can use for editing is available in the Help by selecting Keyboard shortcuts from the Help menu. A summary of the Border script syntax is also available from the Help by selecting Border Script Syntax from the Help menu.
  297.  
  298. Creating a new border
  299. ---------------------
  300. You can create a new border by modifying an existing border, or by starting from scratch with an empty border script. If you want to start a completely new border, you can do so by:
  301. * writing a script directly in the script window
  302. * writing a text file using a word processing package (save the file with a .B extension)
  303. * creating a .WMF format file with a vector drawing package, for example Corel Draw, or MS Draw, then using the Open WMF File command in the File menu
  304. *creating a .GEM format file with a vector drawing package, for example Artline, or GEM Draw, then using the Open GEM File command in the File menu.
  305.  
  306. Whichever way you create the Border Script, you must use Border to execute the .B file containing the script, for use with PowerProject.
  307.  
  308. Writing your own script
  309. -----------------------
  310. If you decide to write your own border script, either in the script window or using a word processor, you should draw the border on paper first. It is much easier to do this if you use graph paper. If you plan to use a standard page size, remember that Border automatically sets all the margins to 10 mm (0.4inch).
  311.  
  312. Once you know how you want your border to look, you should consider the following:
  313. * for accuracy and ease of reading, consider the unit size you need to use. (The default unit size is millimeters.)
  314. * from the position of the margins and the unit size, work out a coordinate system. Remember that 0,0 is the intersection of the left and top margins. Consider using the width and height method of defining coordinates. (Coordinates are explained in Chapter 3: Border script commands.)
  315. * you must include one pagesize and one style command in a script
  316. * for best performance, pagesize should be the first command, and style and chartarea should be near the top of the script
  317. * when you save the new border file, try to include the size and orientation in the filename, for example, USA_A_L.B for an A landscape border. The filename is shown on the PowerProject Print dialog, so a descriptive filename helps you to locate the correct border.
  318.  
  319. NOTE: If you omit the chartarea command, you cannot use the border to frame a PowerProject graphic, but you can use it for other purposes. See Other uses for a border.
  320.  
  321. Script writing process
  322. ----------------------
  323. There are a number of basic steps involved in writing a border script. These steps are:
  324.  
  325. 1. Start Border by double-clicking on the Border program icon.
  326.  
  327. 2. To start a new script, select New from the File menu if the script window is not already empty. An untitled script window is displayed.
  328.  
  329. To modify an existing script, select Open from the File menu and choose the border that you want to edit. When you OK the file selector, the script will be displayed in the script window.
  330.  
  331. 3. Type in the script, or make the changes you want to the existing script.
  332.  
  333. 4. Check the border for errors by selecting Execute from the Options menu.
  334.  
  335. 5. Eliminate any errors and execute the script again until it does not generate any errors.
  336.  
  337. 6. Save the border by selecting Save from the File menu.
  338.  
  339. NOTE: You cannot save the border if it contains an error in the style or pagesize commands.
  340.  
  341. Using a drawing package
  342. -----------------------
  343. You can design your borders using a drawing program. If you choose to create borders in this way, you must save the designs in your drawing package as a WMF or GEM file. To open the design in Border, use the Open WMF File or Open GEM File commands in the File menu. The border script will be generated automatically.
  344.  
  345. A rounded rectangle graphic will be interpreted automatically as the chartarea. If you wish to include a picture command, draw a second rounded rectangle and later edit this second occurrence of the chartarea command to the picture command.
  346.  
  347. The way lines and boxes are converted into Border may result in a number of redundant lines. When you become familiar with the Border commands, you will be able to edit unnecessary lines out of the script and add comment lines to make the border script more concise and easier to read.
  348.  
  349. Other uses for a border
  350. -----------------------
  351. You can create borders without a chartarea command. This can be useful, for example, if you need to print several charts or histograms on a single sheet of paper for a presentation. Output the charts and histograms from PowerProject as WMF files, then create a border using the compulsory commands and several picture commands to load the WMF files. Open the border on the Print Graphics dialog in PowerProject and output to your printer.
  352.  
  353. By using a variety of tokens, and picture commands, you can make impressive presentation sheets and cover sheets for documents.
  354.  
  355.  
  356. Chapter 3: Border script commands
  357. =================================
  358. If you decide to create a new border, or want to make changes to an existing border, you need to understand the commands which make up a border script. You can use border script commands to:
  359. * describe the size, shape and contents of the lines, graphics, text and boxes making up a border
  360. * specify border tokens, which represent information about PowerProject chart and project details on the current project or a baseline of the project.
  361.  
  362. This chapter explains the border script commands and their syntax. If you use Border to convert a file created using a drawing program, all border script commands are generated automatically so you need not be aware of them.
  363.  
  364. Compulsory commands
  365. -------------------
  366. You must include one PAGESIZE and one STYLE command in a script. Although CHARTAREA is not compulsory, you are unlikely to create a border for a graphic without one.
  367.  
  368. For best performance, make PAGESIZE the first command and put STYLE and CHARTAREA near the top of the script.
  369.  
  370. You can only have one PAGESIZE, STYLE and CHARTAREA command in a script.
  371.  
  372. Border script syntax
  373. --------------------
  374. The syntax of commands is simple: a command name followed by a number of arguments which are separated by commas.
  375.  
  376. <command name> <argument1>,<argument2>,...
  377.  
  378. Command names
  379. -------------
  380. Case is not relevant when typing Border command names. For example, you could type topmargin, TopMargin or TOPMARGIN.
  381.  
  382. Arguments
  383. ---------
  384. The arguments take different forms. Depending on the command, they can be text, numbers, coordinates, variables or expressions.
  385.  
  386. Text
  387. ----
  388. Text is enclosed by double quotes, for example:
  389.  
  390. Write "Produced by MIS"
  391.  
  392. Numbers
  393. -------
  394. Numbers are entered in the current unit size, which is millimeters unless you have used the unitsize command.
  395.  
  396. NOTE: The examples in this chapter shown the current unit size as millimeters.
  397.  
  398. Coordinates
  399. -----------
  400. Coordinates must be entered in the current unit size. The coordinate system starts at the intersection of the top and left margins, known as home (0,0). You should set the margins before using any commands with coordinates. 
  401.  
  402. Variables
  403. ---------
  404. Border provides you with two variables which enable you to make borders suitable for use on different paper sizes, or for different orientations.
  405.  
  406. They are 'height' - the vertical depth between top and bottom margins, and 'width' - the horizontal distance between left and right margins. 
  407.  
  408. Expressions
  409. -----------
  410. You can include mathematical operators with a variable, to give an expression. The operators you can use are:
  411.  
  412. Minus     -
  413.  
  414. Plus     +
  415.  
  416. Divide     /
  417.  
  418. Multiply     *
  419.  
  420. For example, you could center 'Management Summary' using the commands
  421.  
  422. ALIGN CENTRE 
  423. //center point between margins, 2 cm from bottom 
  424. MOVETO WIDTH/2, HEIGHT-20 
  425. WRITE "Management Summary"
  426.  
  427. Comments
  428. --------
  429. You can add comments to make a border script easier to understand. Comments can be on a line of their own, or at the end of a line containing a command. Wherever you add a comment, you must start with //, for example:
  430.  
  431. //Draw a box on the paper
  432.  
  433. or
  434.  
  435. BOXTO ... // Draw a box on the paper
  436.  
  437.  
  438. List of commands
  439. ----------------
  440. Commands are listed in alphabetical order in this section. All commands are described as though you were controlling the movement of a pen across a sheet of paper, although the output may be on printer or plotter.
  441.  
  442. At the end of the section are tables which group the commands according to their function.
  443.  
  444.  
  445. ALIGN
  446.  
  447. This command controls the alignment of text you supply with the write command. If you use align left, text is left justified - it is written across the page from left to right from the current pen position. You can change the setting to right if you want the text to be right flush, or centre for text to be centered on the current pen position. You can use the align command anywhere in the script before the write command.
  448.  
  449. Format
  450. ALIGN LEFT | RIGHT | CENTRE
  451.  
  452. Default
  453. The default is ALIGN LEFT.
  454.  
  455. Example
  456. MOVETO    300,300 
  457. ALIGN    LEFT 
  458. WRITE    "Prepared for you by MIS"
  459.  
  460.  
  461. BASELINE
  462.  
  463. Makes border tokens refer to a baseline. The default is that all border tokens refer to the current project. Specify the baseline you want the tokens to refer to, according to the order in which the baselines were created.
  464.  
  465. The earliest baseline is the first baseline that was created from the project and the latest is the most recent baseline. Once you have used this command, all border tokens refer to the specified baseline until you specify that they should refer to the project.
  466.  
  467. Format
  468. BASELINE    EARLIEST | LATEST <baseline number>
  469.  
  470. Default
  471. If you do not use this command, all tokens refer to the current project. If you do not specify a baseline number, PowerProject uses 1 to refer to the earliest or latest baseline.
  472.  
  473. Example
  474. To make the token "<PDB-FILENAME>" refer to the 3rd baseline created for a project
  475.  
  476. BASELINE    EARLIEST 3 
  477. WRITE    "<PDB-FILENAME>"
  478.  
  479. To make tokens refer to the most recent baseline:
  480.  
  481. BASELINE    LATEST
  482.  
  483. To specify that tokens should no longer refer to a baseline, but to the current project, use the project command or use the baseline number 0.
  484.  
  485. BASELINE EARLIEST 0 
  486. or
  487. BASELINE LATEST 0
  488.  
  489. Associated commands
  490. PROJECT
  491.  
  492.  
  493. BOLD
  494.  
  495. Turn bold text on or off. The default is off, so if you want text in bold, you
  496. can turn it on. At the end of bold text, turn it off.
  497.  
  498. Format
  499. BOLD    ON | OFF
  500.  
  501. Default
  502. Bold is off until you turn it on.
  503.  
  504. Example
  505. To produce 'Prepared for you by MIS' in bold
  506.  
  507. BOLD    ON
  508. WRITE    "Prepared for you by MIS"
  509. BOLD    OFF
  510.  
  511.  
  512. BOTTOMMARGIN
  513.  
  514. Set the height of the bottom margin. If you are printing on a printer or plotter which has mandatory margins, you must use this command to make a bottom margin to ensure your border is on a printable part of the page. Check your printer manual to find out if your printer expects a minimum margin.
  515.  
  516. Format
  517. BOTTOMMARGIN    <HEIGHT>
  518.  
  519. Default
  520. If you do not use this command, for custom page size the bottom margin is set to zero. For the standard page sizes, the bottom margin is set to 10 mm (0.4 inch).
  521.  
  522. Example
  523. To set a bottom margin of 10 mm (0.4 inch):
  524.  
  525. BOTTOMMARGIN 10
  526.  
  527.  
  528. BOXTO
  529.  
  530. Draw a hollow box from the current pen position to the coordinates you supply. Before using boxto you should move the current pen position to the start of the box, for example the top left corner, using moveto.
  531.  
  532. You can also use the variables height and width to draw a box relative to the paper width.
  533.  
  534. After drawing the box, the pen position is set to the coordinates you supplied. For example, if you start the box at the top left hand corner, the pen finishes at the bottom right corner of the box.
  535.  
  536. Format
  537. BOXTO    <RIGHTEDGE(X)>,<BOTTOMEDGE(Y)>
  538.  
  539. Default
  540. No default: you must supply the coordinates.
  541.  
  542. Example
  543. To draw a box 10mm from the top and left margins which is 20 mm square:
  544.  
  545. MOVETO    10,10 
  546. BOXTO    30,30
  547.  
  548. To draw a box on the margins on any paper size
  549.  
  550. MOVETO    0, 0 //HOME 
  551. BOXTO    WIDTH, HEIGHT
  552.  
  553. Associated commands
  554. MOVETO, COLOR, UNITSIZE
  555.  
  556.  
  557. CHARTAREA
  558.  
  559. This is a key command in a Border Script. Use it to define the part of the page onto which PowerProject should place your graphic (chart, histogram or calendar). If the CHARTAREA command is not included in your script, PowerProject has nowhere to place a chart in the final output.
  560.  
  561. The CHARTAREA is a rectangle starting from the current pen position, ending according to the coordinates you supply. It must be within the margins. You can use the variables height and width to set the CHARTAREA, but if you do, the PAGESIZE command must precede CHARTAREA.
  562.  
  563. After setting the CHARTAREA, the pen position is set to the coordinates you supplied.
  564.  
  565. Format
  566. CHARTAREA    <RIGHTEDGE(X)>,<BOTTOMEDGE(Y)>
  567.  
  568. Default
  569. None. Although this command is not compulsory, if you save a border without a CHARTAREA, you should have a specific reason for doing so because PowerProject cannot use it as a border for a chart. You might omit the CHARTAREA command for example, if you want to produce a cover page for your charts containing project or chart details using tokens.
  570.  
  571. Example
  572. The examples show CHARTAREA set using the HEIGHT and WIDTH variables, since the border is then more flexible. However, you can measure the exact size of the chartarea, and supply these figures as coordinates.
  573.  
  574. To set a CHARTAREA which is 1 mm from the left and right margins, 4 cm below the top margin and 2 cm above the bottom margin,
  575.  
  576. MOVETO    1, 40 //1mm from left, 4cm from top 
  577. CHARTAREA    WIDTH-1, HEIGHT-20 
  578. //1mm from right, 2 cm from bottom
  579.  
  580. To set a chart area which is the full width of the page, leaving an area of 10 cm at the bottom
  581.  
  582. MOVETO    0, 0, 
  583. CHARTAREA    WIDTH, HEIGHT-100
  584.  
  585.  
  586. COLOR
  587.  
  588. Select the pen color to be used for all subsequent drawing commands. You can change color as often as you like. The sixteen colors you can choose from are: BLACK, BLUE, DARKGREY, DARKBLUE, CYAN GREEN, DARKCYAN, DARKGREEN, MAGENTA, RED, DARKMAGENTA, DARKRED, WHITE, GREY, YELLOW, DARKYELLOW.
  589.  
  590. Format
  591. COLOR <COLOR> 
  592. or 
  593. COLOUR <COLOUR>
  594.  
  595. Default
  596. If you do not specify a color, the default is black
  597.  
  598. Example
  599. To change the color to darkred
  600.  
  601. COLOR    DARKRED 
  602. WRITE    "Prepared for you by MIS"
  603.  
  604.  
  605. FILLTO
  606.  
  607. FILLTO is similar to the BOXTO command, but it produces a solid box, coloured in the current color setting - default black.
  608.  
  609. You can use this command to produce a thick line by making a long thin box. You can also use it to fill any part of the border or chart area to enhance the presentation of a chart.
  610.  
  611. After drawing and filling the box, the pen position is set to the coordinates you supplied.
  612.  
  613. Format
  614. FILLTO    <RIGHTEDGE(X)>,<BOTTOMEDGE(Y)>
  615.  
  616. Default
  617. No default: you must supply the coordinates.
  618.  
  619. Example
  620. To draw a red line, 1 mm thick, just inside the margins
  621.  
  622. MOVETO    0, 0 //Home 
  623. COLOUR    RED 
  624. FILLTO    WIDTH, 1 
  625. FILLTO    WIDTH-1, HEIGHT 
  626. FILLTO    0, HEIGHT-1 
  627. FILLTO    1, 1
  628.  
  629. Associated commands
  630. MOVETO, COLOR, UNITSIZE
  631.  
  632.  
  633. ITALIC
  634.  
  635. Turn italic on or off. The default is off, so if you want text printed in italics, you must turn it on. At the end of the italic text, you must turn it
  636. off.
  637.  
  638. Format
  639. ITALIC    ON | OFF
  640.  
  641. Default
  642. Italic is off until you turn it on.
  643.  
  644. Example
  645. To produce 'Prepared for you by MIS' in italics:
  646.  
  647. ITALIC    ON 
  648. WRITE "Prepared for you by MIS"
  649. ITALIC    OFF
  650.  
  651.  
  652. LEFTMARGIN
  653.  
  654. Set the width of the left margin. If you are printing on a printer or plotter which has mandatory margins, you must use this command to make a left margin to ensure your borders are on a printable part of the page. Check your printer manual to find out if your printer expects a minimum margin.
  655.  
  656. Home - coordinate 0,0 - is the intersection of the top and left margins. You should set the margins at the beginning of a border script. Once you have set them, and established your coordinate system, you should not change their positions.
  657.  
  658. Format
  659. LEFTMARGIN    <WIDTH>
  660.  
  661. Default
  662. If you do not use this command, for custom page size the left margin is set to zero. For the standard page sizes, the left margin is set to 10 mm.
  663.  
  664. Example
  665. To set a left margin of 10mm (0.4 inch):
  666.  
  667. LEFTMARGIN 10
  668.  
  669.  
  670. LINETO
  671.  
  672. Draw a line in the selected color from the current pen position. You supply the length and direction of the line by supplying the coordinates for the end pen position.
  673.  
  674. After drawing the line, the pen position is set to the coordinates you supplied.
  675.  
  676. Format
  677. LINETO    <RIGHT(X)>,<BOTTOM(Y)>
  678.  
  679. Example
  680. To draw a line along the top margin
  681.  
  682. MOVETO    0, 0 
  683. LINETO    WIDTH, 0
  684.  
  685. Associated commands
  686. MOVETO, COLOR, UNITSIZE
  687.  
  688.  
  689. MOVETO
  690.  
  691. Move the pen to the location supplied by the coordinates. The pen position is in current unit size. You need to use this command to position the pen before CHARTAREA, PICTURE, WRITE, LINETO, BOXTO or FILLTO.
  692.  
  693. Format
  694. MOVETO    <X-POSITION>,<Y-POSITION>
  695.  
  696. Default
  697. The pen position is initially set to 0,0
  698.  
  699. Example
  700. To locate the pen 1 mm from the left margin and 40 mm below the top margin:
  701.  
  702. MOVETO    1, 40
  703.  
  704. Associated commands
  705. BOXTO, FILLTO, LINETO, PICTURE, WRITE
  706.  
  707.  
  708. PAGESIZE
  709.  
  710. You must include this command in a border script, to set the page size.
  711.  
  712. There are two ways you can set the page size: by supplying a page type and orientation from the list below, or by creating a custom page type by supplying the pages height and width in current unit size.
  713.  
  714. Whichever method you choose, the height and width variables are automatically set according to your pagesize command. You must set the PAGESIZE before using variables.
  715.  
  716. Page types recognized by Border are: A0, A1, A2, A3, A4, A5, B5, Broad, Half, Ledger, Legal, Letter, Wide.
  717.  
  718. Page orientation: landscape - short side of paper vertical, or: portrait - long side of paper vertical.
  719.  
  720. Format
  721. PAGESIZE    <PAGETYPE>, PORTRAIT | LANDSCAPE
  722.  
  723. or
  724.  
  725. PAGESIZE    CUSTOM,<PAGEWIDTH(X)>,<PAGEHEIGHT(Y)>
  726.  
  727. Default
  728. There is no default for PAGESIZE - you must include this command.
  729.  
  730. Example
  731. To set the page size to the standard A size, portrait orientation:
  732.  
  733. PAGESIZE    A, PORTRAIT
  734.  
  735. To set the page size to 100 mm square:
  736.  
  737. PAGESIZE    CUSTOM, 100, 100
  738.  
  739.  
  740. PICTURE
  741.  
  742. Load a graphics image from a .WMF or .BMP file into a rectangle drawn from the current pen position and ending according to the coordinates you supply.
  743.  
  744. NOTE: Some Windows 3.0 printer and plotter drivers will not print BMP files. So ensure that you have the latest driver for your printer or plotter.
  745.  
  746. The image, for example a logo, is scaled to fit the given rectangle.
  747.  
  748. After the picture command, the pen position is set to the coordinates you supplied.
  749.  
  750. When you Execute the border, the border window shows the logo in the desired location.
  751.  
  752. To ensure that your graphic is the right way up, first moveto the top left hand corner of the area where you want to position your graphic file. Use the picture command to supply the .WMF or .BMP file name and the bottom right hand coordinates.
  753.  
  754. Format
  755. PICTURE    "<FILENAME>",<RIGHTEDGE(X)>,<BOTTOMEDGE(Y)>
  756.  
  757. Default
  758. None
  759.  
  760. Example
  761. To load a file called LOGO.BMP into a 30 mm square box
  762.  
  763. MOVETO    0,0 
  764. //go to the top left hand of the box
  765. PICTURE    "C:\ARTWORK\LOGO.BMP",30,30 
  766. //draw the picture
  767. MOVETO    0,0 
  768. //return to top left hand coordinate for the box
  769. BOXTO    30,30 
  770. //draw a line to surround the logo
  771.  
  772. NOTE: It is recommended that the full path name of .WMF and .BMP files are included in a border file, to prevent problems during output.
  773.  
  774.  
  775. PROJECT
  776.  
  777. Makes border tokens refer to the current project. Use this command if you have previously made all tokens refer to a baseline of the current project, using the baseline command.
  778.  
  779. Format
  780. This command has no arguments.
  781.  
  782. Default
  783. The default is that border tokens refer to the current project.
  784.  
  785. Example
  786. To write out the end date of the first baseline and underneath it write out the end date of the current project
  787.  
  788. TEXTSIZE    10 
  789. MOVETO    0,0 
  790. BASELINE    EARLIEST 
  791. WRITE    "<PROJ-END>" 
  792. PROJECT
  793. MOVETO    0,10
  794. WRITE    "<PROJ-END>"
  795.  
  796.  
  797. RIGHTMARGIN
  798.  
  799. Set the width of the right margin.
  800.  
  801. If you are printing on a printer or plotter which has mandatory margins, you must use this command to make a right margin to ensure your borders are on a printable part of the page. Check your printer manual to find out if your printer expects a minimum margin.
  802.  
  803. Format
  804. RIGHTMARGIN <WIDTH>
  805.  
  806. Default
  807. If you do not use this command, for custom pagesize the right margin is set to zero. For the standard pagesizes, the right margin is set to 10 mm.
  808.  
  809. Example
  810. To set a right margin of 10 mm (0.4 inch):
  811.  
  812. RIGHTMARGIN 10
  813.  
  814.  
  815. STYLE
  816.  
  817. You must use this command to give the border a name. It is not printed on the border, but is displayed by PowerProject on the Print Graphics dialog, where you can select the border to be used to surround your output.
  818.  
  819. Format
  820. STYLE    "<freetext>"
  821.  
  822. Default
  823. There is no default. Every script must include the style command.
  824.  
  825. Example
  826. STYLE    "A Portrait Border for Acme Supplies"
  827.  
  828.  
  829. TEXTSIZE
  830.  
  831. Set the height of text characters in current unit size.
  832.  
  833. Border allows you to enter any number, and text is displayed in the size you have indicated. However, you must select a size which can be produced by your output device. If you are using a plotter or Postscript printer, any size can be matched exactly. For output on all other printers, you should limit the text sizes you choose to those provided by the printers fonts. If you use text sizes which are not available, PowerPrint chooses the closest size available.
  834.  
  835. Format
  836. TEXTSIZE <Characterheight>
  837.  
  838. Example
  839. To set the height of characters to 10 mm, which would need a large printer font of 28 point.
  840.  
  841. TEXTSIZE 10
  842.  
  843. The character height (in mm) to use for the commonest point sizes:
  844.  
  845. Point size          mm
  846. 6                   2.1
  847. 8                   2.8
  848. 10                  3.5
  849. 12                  4.2
  850. 14                  4.9
  851. 16                  5.6
  852. 18                  6.3
  853. 20                  7.1
  854.  
  855.  
  856. TOPMARGIN
  857.  
  858. Set the height of the top margin in current unit size.
  859.  
  860. If you are printing on a printer or plotter which has mandatory margins, you must use this command to make a top margin to ensure your borders are on a printable part of the page. Check your printer manual to find out if your printer expects a minimum margin.
  861.  
  862. The intersection of the top margin and left margin is the start of the coordinate system - home - 0,0.
  863.  
  864. Format
  865. TOPMARGIN <HEIGHT>
  866.  
  867. Default
  868. If you do not use this command, for custom pagesize the top margin is set to zero. For the standard pagesizes, the top margin is set to 10 mm.
  869.  
  870. Example
  871. To set a top margin of 20 mm (0.8inch):
  872.  
  873. TOPMARGIN 20
  874.  
  875.  
  876. UNDERLINE
  877.  
  878. Turn underline on or off. The default is off, so if you want text underlined, you must turn it on. At the end of the text you want to underline, you must turn it off.
  879.  
  880. Format
  881. UNDERLINE ON | OFF
  882.  
  883. Default
  884. Underline is off until you turn it on.
  885.  
  886. Example
  887. To produce 'Prepared for you by MIS' underlined:
  888.  
  889. UNDERLINE    ON
  890. WRITE    "Prepared for you by MIS"
  891. UNDERLINE    OFF
  892.  
  893. You can set more than one attribute for text, for example to have the text in bold, and underlined:
  894.  
  895. UNDERLINE    ON 
  896. BOLD    ON 
  897. WRITE    "Prepared for you by MIS"
  898. BOLD    OFF 
  899. UNDERLINE    OFF
  900.  
  901.  
  902. UNITSIZE
  903.  
  904. Use this command to change the units you use to supply numbers and coordinates. You supply the size of the unit you want to use, in 1/10s of a millimeter.
  905.  
  906. Format
  907. UNITSIZE    <newsize>
  908.  
  909. Default
  910. Unless you use this command to change current units, the current unit size is millimeters.
  911.  
  912. Examples
  913. To change to inches and move the pen
  914.  
  915. //Give measurements in inches (254*1/10mm = 1") 
  916. UNITSIZE    254
  917. //Move 1" across and 1" down page from origin 
  918. MOVETO    1, 1
  919.  
  920. To change to centimeters
  921.  
  922. UNITSIZE    100 
  923. //Give measurements in centimeters
  924.  
  925. WRITE
  926.  
  927. Write the text you supply in double quotes at the current pen position. Use this command to place the text you supply anywhere within the margins. You can use insert project details into a border by supplying a token name in double quotes.
  928.  
  929. First move the pen to the required start position using MOVETO. If you want to change color or start underlining or writing in bold, do so before using the WRITE command. You should also use the ALIGN command before write.
  930.  
  931. When the text has been written, the pen returns to the start position.
  932.  
  933. Format
  934. WRITE    "<freetext>"
  935.  
  936. Default
  937. none
  938.  
  939. Example
  940. To write a string of text:
  941.  
  942. WRITE    "Prepared for you by MIS"
  943.  
  944. To include the start date taken from your chart, use a token
  945.  
  946. WRITE "Chart Start Date: <CHART-START>"
  947.  
  948. Associated commands
  949. ALIGN, BOLD, COLOR, ITALIC, MOVETO, TEXTSIZE, UNDERLINE
  950.  
  951.  
  952. Summary of commands
  953. -------------------
  954.  
  955. Text commands
  956. -------------
  957. MOVETO    <X VALUE>,<Y VALUE>
  958. ALIGN    LEFT | RIGHT | CENTRE
  959. BOLD    ON | OFF
  960. COLOR    BLACK | BLUE | CYAN | GREEN MAGENTA | RED | WHITE | YELLOW GREY | DARKGREY | DARKBLUE DARKCYAN | DARKGREEN | DARKMAGENTA DARKRED | DARKYELLOW
  961. ITALIC    ON | OFF
  962. TEXTSIZE    <VALUE>
  963. UNDERLINE    ON | OFF
  964. WRITE    "<TEXT>"
  965.  
  966. Margin commands
  967. ---------------
  968. BOTTOMMARGIN    <VALUE>
  969. TOPMARGIN    <VALUE>
  970. LEFTMARGIN    <VALUE>
  971. RIGHTMARGIN    <VALUE>
  972.  
  973. Box and line commands
  974. ---------------------
  975. MOVETO    <X VALUE>,<Y VALUE>
  976. BOXTO    <X VALUE>,<Y VALUE>
  977. FILLTO    <X VALUE>,<Y VALUE>
  978. LINETO    <X VALUE>,<Y VALUE>
  979.  
  980. Other commands
  981. --------------
  982. UNITSIZE    <VALUE>
  983. CHARTAREA    <X VALUE>,<Y VALUE>
  984. PICTURE    "<FILENAME.WMF>",<X VALUE>,<Y VALUE>
  985. BASELINE    EARLIEST | LATEST <BASELINE NUMBER>
  986. PROJECT    no arguments
  987.  
  988. Compulsory commands
  989. -------------------
  990. STYLE "<TEXT>"
  991. PAGESIZE CUSTOM,<X VALUE>,<Y VALUE> 
  992. or 
  993. PAGESIZE A0 | A1 | A2 | A3 | A4 | A5 | B5| BROAD | HALF | LEDGER | LEGAL LETTER | WIDE ,PORTRAIT | LANDSCAPE
  994.  
  995. Editing keys in script window
  996. -----------------------------
  997. HOME Start of line
  998. END End of line
  999. PGUP Page up
  1000. PGDN Page down
  1001. CTRL Word right
  1002. CTRL Word left
  1003. CTRL HOME Start of file
  1004. CTRL END End of file
  1005. + (on numeric keypad) Copy line to Clipboard
  1006. - (on numeric keypad) Paste line to Clipboard
  1007. INS Insert line from Clipboard
  1008. CTRL G Goto line...
  1009. CTRL N Next error
  1010. CTRL P Previous error
  1011.  
  1012. In error window
  1013. ---------------
  1014. ALT click Go to error line in script window
  1015.  
  1016.  
  1017.  
  1018. Copyright (c) 1997 Asta Group plc. All rights reserved.
  1019.