DHTMLX Docs & Samples Explorer

Index
dhtmlxwindows

## Buttons Settings Manipulations

### Button Accessing

A button can be accessed in the following way:

        var btn = dhxWins.window(id).button(id);

Default buttons ids are:

- “stick” for “Stick” button;
- “sticked” for “Sticked” button (pressed “stick”, used for “unstuck” action);
- “help” for “Help” button;
- “park” for “Park” button;
- “minmax1” for “Maximize” button;
- “minmax2” for “Minimize” button;
- “close” for “Close” button;
- “dock” for “Dock” button (appears automaticaly instead of close button in case of cell undocking).

### Showing/Hiding Buttons

There is the possibility to show/hide a button by calling the following methods:

        dhxWins.window(id).button(id).show();
        dhxWins.window(id).button(id).hide();

User-buttons also inherit these methods.

### Button Enabling/Disabling

The button can be enabled/disabled by user:

        dhxWins.window(id).button(id).enable();
        dhxWins.window(id).button(id).disable();

User-buttons also inherit these methods.

Note: in some cases button enabling/disabling is determined by Object. For example, when the window is Parked Up, resize buttons are inactive/disabled. But they become active/enabled when the window is Parked Down. Thus, resize buttons are disabled by Object.

Creating user button guide coming soon.