What Are Commands?

Commands are used to perform an action related to the application interface. For the most part, commands mimic menu options and tend to be used primarily in action buttons, hotspots, agents, and events. For example, commands can be used to

Note

@Commands cannot be called from LotusScript and, with few exceptions, cannot be implemented in Web-based applications.

The following table represents some of the most frequently used commands. In most cases, these commands would be placed in an action button for a given form.

Command

Description

Example

FileSave

Saves the document currently displayed in the Lotus Notes client. Syntax:

@Command ( [FileSave] );  

@Command ([FileSave]);  

EditDocument

Toggles between edit and read mode for the currently opened document. Optionally, if you set the edit mode to 1, the document only goes to edit mode. If the mode is set to 0, the document goes to read mode. Syntax:

@Command([EditDocument]; mode; pane)  

modeSet to 1 for edit, 0 for readonly.

paneSet to 1 to display in preview pane.

@Command ([EditDocument]; 1)  

CloseWindow

Closes the document currently open in the Lotus Notes client. Syntax:

@Command ( [CloseWindow] );  

@Command ([CloseWindow]);  

Compose

Creates a new document based on the specified form. Syntax:

@Command ([Compose]; form);  

formAn existing form in the database.

@Command([Compose]; "NewEmployee");  

EditGoto-Field

Places the cursor in the specified field on the document. Syntax:

@Command ([EditGotoField]; fieldname);  

fieldnameName of a field on a form.

@Command ([EditGotoField]; "Title");  

Категории