Toolbar Tutorial - Adding a Dropdown Menu


In this example, we add a dropdown menu to the Home button. The menu contains 4 links and a separator.

Note the new dropdown arrow next to the button. If you click on it, the Menu() function will bring up the popup menu that we have defined in the MENUDEFINITIONS block.


<XML id="toolbar">
<TOOLBAR caption="Toolbar Tutorial">
<control type="toolbar">
<button id="home"

    caption=" "
    tooltip=" Home Page">

<dropdown action="Menu(links)"></dropdown>

<control type="combo" id="query" action="Command(search)" width=120></control>
<control type="toolbar">
<button caption="Search" tooltip="Search" image="" action="Command(search)"></button>

    <menu id="links">
      <option caption="" action=""></option>
      <option caption="Software" action=""></option>
      <option caption="Music" action=""></option>
      <option caption="Games" action="" image=""></option>



    <command id="search" action=""></command>




  • Note the smiley image on the Games menu option.