The FindCommandInCmdList() function defined in the syCmdBarBtnObj form in Microsoft Dynamics GP is used to find the location of a command or command list in an existing command list, such as one used for a toolbar.
FindCommandInCmdList(UserID, ParentDictID, ParentFormID, ParentCmdID, CmdDictID, CmdFormID, CmdID)
• UserID – A string that specifies which user’s set of commands will be examined to find the position of the command in the command list. Specify the empty string ("") to examine the default set of commands.
• ParentDictID – The ID of the dictionary that contains the command list that is being examined. Use the constant DYNAMICS to specify the Microsoft Dynamics GP main dictionary.
• ParentFormID – The resource ID of the command form that contains the definition of the command list that is being examined.
• ParentCmdID – The resource ID of the command list that is being examined.
• CmdDictID – The ID of the dictionary that contains the command whose location is being examined.
• CmdFormID – The resource ID of the command form that contains the definition of the command whose location is being examined.
• CmdID – The resource ID of the command whose location is being examined.
An integer that specifies the location (sequence number) of the specified command. The value 0 indicates the item was not found in the command list.