Toolbar Browser
3. Reference
Triggers
OnBeginLoad
OnLoad
OnChange
OnActivate
OnSelect
OnFocus
OnKillFocus
OnRank
OnSave
Controls
Variables
System Variables
Global Values
Functions
Text Functions
 

OnFocus Trigger

The onfocus trigger is activated when a combo or an edit control gains the input focus.

Syntax:

    onfocus="Function(); Function2(); ..."


Remarks:

  • This trigger only works with combo and edit box controls.



Example:

    <xml id="toolbar">
    <toolbar caption="OnFocus Example">
    <control type="edit" bgcolor="white"

      onfocus="SetParam(this,bgcolor,#FFFF00)"
      onkillfocus="SetParam(this,bgcolor,WHITE)"
      id="query"
      width=140
    ></control>

    </toolbar>
    </xml>


    In the above example, when the edit control gains the input focus, the onfocus trigger changes the background color to yellow. When it looses the focus, the background color changes to white.



Compatibility

    Requires ToolbarBrowser v2.4.3 and later.


See Also: