Calling a public sub from script library in a button

I have a button on a form and am using Lotus Script. I can’t see to call a public sub from a scrpit library in the lotus script. Should I be able to? I have “Use Public Routies” in the options portion of the button and the form.

Subject: Calling a public sub from script library in a button

The best way to do this is to create a class…this way any other subs or functions can easily be instantiated for future use.

In the declarations section of the script library, for example:

Class Car

'any global variable declarations

Dim engineType As String

Function Engine() As String

Engine = “LT1-350”

End Function

End Class

Then in your button, with the Use keyword pointed at your script library:

Dim myCar As New Car

Dim myEngine As String

myEngine = myCar.Engine

myEngine contains the value “LT1-350”

Try to do everyting with classes…make your code object-oriented…just my opinion

Subject: In the Globals section of the form, on the line following ‘Option Public’…

putUse “YourScriptLibrary”

Then just call the function from your button on the form.