Using Visual LISP Projects

AutoCAD Visual LISP

 
Using Visual LISP Projects
 
 
 

The VLISP project feature provides a convenient way to manage the files that make up your application. And with the project feature, you can open a single project file instead of individually opening every LISP file in the application. Once the project is open, getting to its constituent files is a double-click away.

To create a VLISP project

  1. Choose Project New Project from the VLISP menu.
  2. Save the file in your Lesson4 directory, using the name gpath.prj.

    After you save the file, VLISP displays the Project Properties dialog box.

  3. Choose the [Un]Select All button on the left in the Project Properties dialog box.
  4. Choose the button containing an arrow pointing to the right. This adds all the selected files to your project.

    In the Project Properties dialog box, the list box on the left shows all LISP files that reside in the same directory as your project file and are not included in that project. The list box on the right lists all the files that make up the project. When you add the selected files to the project, those file names move from the left box to the right box.

  5. In the list box on the right side of the dialog box, select gpmain, then choose the Bottom button. This moves the file to the bottom of the list.

    VLISP loads project files in the order they are listed. Because the prompt that tells users the name of the command is located at the end of the gpmain.lsp file, you need to move this file to the bottom of the list. Loading this file last results in the prompt displayed to users. The utils.lsp file should be loaded first because it contains initialization code for the application. Therefore, select utils in the dialog's list box and choose the Top button.

  6. Choose OK.

VLISP adds a small project window to your VLISP desktop. The window lists the files in your project. Double-click on any file to open the file in the VLISP text editor (if it is not already open) and make it the active editor window.