Cadcorp SIS API Methods

AllowCommands Method

Description

Add or remove commands from the menu. To find the ACom equivalent for a menu command, turn on the Developer Control Bar, select the command, and the ACom equivalent will be displayed in the Developer Control Bar.

Syntax

Visual Basic
Public Function AllowCommands( _
   ByVal flag As Integer, _
   ByVal listcom As String _
) As Integer

Parameters

flag
SIS_COM_ALL    allow all commands.
SIS_COM_ADD    add the command(s) specified in listcom.
SIS_COM_REMOVE remove the command(s) specified in listcom.
SIS_COM_NONE disallow all commands.
listcom
 a list of commands separated by space, comma, tab, or newline characters.

Remarks

If you want the user to have access to only a few commands, you can remove all commands using SIS_COM_NONE and then, using SIS_COM_ADD, add back the allowed commands.

Commands removed in this way disappear from the menu, but can still be run using other API methods.

Available: MD ME MM OD OM OV

Groups:

Example

sis.AllowCommands (SIS_COM_REMOVE, "AComLayers, AComCopy, AComPaste")

removes the Overlays, Copy, and Paste commands from the main and local menus


Send comments on this topic.

Click to return to www.cadcorp.com

© Copyright 2000-2017 Computer Aided Development Corporation Limited (Cadcorp).