Jade 7

Instructions

  1. In the Class Browser, select the JadeScript class.
  2. Select the Methods | New JADE Method... command.
    The JADE Method Definition dialog is displayed.
  3. Enter checkOutBooks and click the OK button. A skeleton method is created for you to code.
  4. Select the code on the left by clicking and dragging.
  5. Copy the code to the clipboard (CTRL-C).
  6. Select all the code in the code window (CTRL-A).
  7. Paste the code from the clipboard (CTRL-V).
  8. Select the Methods | Compile Method menu command.
    The status line in the Class Browser displays
    «Compilation complete - no errors»
  9. Select the Jade | Execute it menu command.
    The status line will then display the message
    «Execution complete»

Troubleshooting

If your code did not compile, an error message displays on the status line. Click an error message to find out what to do.

Error 6050 - Cannot change name

Error 6026 - Unknown property or method

Error 6090 - Cannot access protected property or method

checkOutBooks();

vars
    brw : Borrower;    // brw is of type Borrower
    bk1, bk2 : Book;   // bk1 and bk2 are of type Book

begin
    // assign values to variables
    brw := Borrower.firstInstance;
    bk1 := Book.firstInstance;
    bk2 := Book.lastInstance;

    beginTransaction;  // required for database changes

    // check out the books to the borrower
    bk1.myBorrower := brw;
    bk2.myBorrower := brw;

    commitTransaction; // update and release locks
end;

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 Contents
 

For maximum reliability, security and performance of your JADE solution, JADE Care24 is our fully comprehensive systems management offering.