Determining which product file is being used

On Windows, and some other platforms, you can use command-line arguments to start programs and open product files.

The Command function returns the command-line arguments used to start the HCL software application where LotusScript® was invoked. You can use it to get the name of the product file. For example, you may use the file name to identify which product file is currently running, or to provide input for messages to the user.

Dim message As String, messageTitle As String
messageTitle$ = Command$
...
...
' Use messageTitle$ as the title of a message box.
message = "This is a test."
MessageBox message$, messageTitle$

Displays a message box entitled busgoals.lwp