LOTUSSCRIPT LANGUAGE


Using Script Libraries with LS2J
This demonstrates how you might create your own Java Script Library and include it in your LotusScript application using LS2J.

1. Create a Java Script Library called xlib containing the following:


2. Create a LotusScript Agent which uses the library
Run the program. The answer is 50.

Description of the USE statement

The syntax of the LotusScript USE statement is:


The Use statement examines the type of the Script Library. If the Script Library contains LotusScript, processing proceeds as before. If the Script Library contains Java classes, the contained Java classes are available to the LotusScript program by using LS2J.

Note The restriction on using the LotusScript "Use" statement to incorporate a Script Library containing Java has been lifted.

See Also