By Wayne Brill
You can use the HiddenCommands function to hide commands in Vault Explorer. If this function returns names of commands they will be hidden. To get the names of Vault commands you can use the CommandIds property of the IApplication that is passed into the OnLogOn function:
public void OnLogOn(IApplication application) { System.Collections.Generic.IEnumerable cmds = application.CommandIds; }
Here is an example that uses HiddenCommands() to hide the Checkout, CheckIn and Rename commands.
public IEnumerable HiddenCommands() { IEnumerable cmdsToHide = new string[] { "QuickCheckOut", "CheckIn", "Rename" }; return cmdsToHide; }
To test this you can use the HelloWorld SDK sample:
C:Program Files (x86)AutodeskAutodesk Vault 2016 SDKvs12CSharpHelloWorld
See this post for an example code that you can use to display the command id (a string) every time you invoke a command in Vault explorer.

Leave a Reply