Adding Reactor Callback Functions

The reactor callback functions add a substantial amount of code to your application. This code is provided for you in the Lesson6 directory.

To add the reactor callback functions to your program

  1. Copy the gpreact.lsp file from the Tutorial\VisualLISP\Lesson6 directory to your MyPath working directory.
  2. Open the GPath project (if it is not already open), and click the Project Properties button in the gpath project window.
  3. Add the gpreact.lsp file to your project.
  4. The gpreact.lsp file can reside anywhere in the order of files between utils.lsp, which must remain first, and gpmain.lsp, which should remain as the last file. Move any files, if necessary, then click OK.
  5. Open the gpreact.lsp file by double-clicking on the file name within the gpath project window.

Read through the comments in the file to help you understand what it is doing. Note that all the callback functions are stubbed out; the only functionality they perform is to display alert messages when they are fired.

The last function in the file is so important it deserves a heading of its own.