NOTE: If no buttons are initially visible, then add toolbar button names to the toolbar_buttons array of title preset used in combined_header block.
- go to any section, that has a toolbar (grid or edit template)
- add visible toolbar button using a_toolbar.AddButton( new ToolBarMarkup('test_tb1', 'custom tbdata1') ); code (before a_toolbar.Render(); call)
- confirm, that button is visible
- add hidden toolbar button using a_toolbar.AddButton( new ToolBarMarkup('test_tb2', 'custom tbdata2', true) ); code (before a_toolbar.Render(); call)
- confirm, that button is hidden
- dynamically hide initially visible button using a_toolbar.HideButton('test_tb1'); code (after a_toolbar.Render(); call)
- confirm, that button is hidden
- dynamically show initially hidden button using a_toolbar.ShowButton('test_tb2'); code (after a_toolbar.Render(); call)
- confirm, that button is visible
Before made code changes attempt to hide/show toolbar button would result in JavaScript error.