The ButtonsExistForProduct() function defined in the syCmdBarBtnObj form is provided by Microsoft Dynamics GP so you can easily determine whether any toolbar buttons have been defined for an integrating product.
ButtonsExistForProduct(Product_ID)
• Product_ID– The ID of the dictionary for which toolbar buttons will be examined.
A boolean. The value true indicates that toolbar buttons exist for the product, while false indicates they do not.