# wxEditableListBox Class Reference
[Controls]

`#include <wx/editlbox.h>`

Inheritance diagram for wxEditableListBox:
[legend]

## Detailed Description

An editable listbox is composite control that lets the user easily enter, delete and reorder a list of strings.

## Styles

This class supports the following styles:

- wxEL_ALLOW_NEW:
  Allows the user to enter new strings.
- wxEL_ALLOW_EDIT:
  Allows the user to edit existing strings.
- wxEL_ALLOW_DELETE:
  Allows the user to delete existing strings.
- wxEL_NO_REORDER:
  Does not allow the user to reorder the strings.
- wxEL_DEFAULT_STYLE:
  Default style: wxEL_ALLOW_NEW|wxEL_ALLOW_EDIT|wxEL_ALLOW_DELETE.

The control uses a wxListCtrl internally and emit its events.

##

Library: wxAdvanced

Category: Controls

See also:
  wxListBox, wxListCtrl

## Public Member Functions
| wxEditableListBox ()
| Default ctor.
| wxEditableListBox (wxWindow *parent, wxWindowID id, const wxString &label, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=wxEL_DEFAULT_STYLE, const wxString &name=wxEditableListBoxNameStr)
| Constructor, creating and showing a list box.
virtual | ~wxEditableListBox ()
| Destructor, destroying the list box.
bool | Create (wxWindow *parent, wxWindowID id, const wxString &label, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=wxEL_DEFAULT_STYLE, const wxString &name=wxEditableListBoxNameStr)
| Creates the editable listbox for two-step construction.
void | SetStrings (const wxArrayString &strings)
| Replaces current contents with given strings.
void | GetStrings (wxArrayString &strings) const
| Returns in the given array the current contents of the control (the array will be erased before control's contents are appended).

List of all members.

## Constructor & Destructor Documentation

wxEditableListBox::wxEditableListBox | ( |  | ) |

Default ctor.

wxEditableListBox::wxEditableListBox | ( | wxWindow * | parent,
|  | wxWindowID | id,
|  | const wxString & | label,
|  | const wxPoint & | pos = `wxDefaultPosition`,
|  | const wxSize & | size = `wxDefaultSize`,
|  | long | style = `wxEL_DEFAULT_STYLE`,
|  | const wxString & | name = `wxEditableListBoxNameStr` |
| ) |  |  |

Constructor, creating and showing a list box.

Parameters:

  | parent | Parent window. Must not be NULL.
  | id | Window identifier. The value wxID_ANY indicates a default value.
  | label | The text shown just before the list control.
  | pos | Window position. If wxDefaultPosition is specified then a default position is chosen.
  | size | Window size. If wxDefaultSize is specified then the window is sized appropriately.
  | style | Window style. See wxEditableListBox.
  | name | Window name.

See also:
  Create()

virtual wxEditableListBox::~wxEditableListBox | ( |  | ) | `[virtual]`

Destructor, destroying the list box.

## Member Function Documentation

bool wxEditableListBox::Create | ( | wxWindow * | parent,
|  | wxWindowID | id,
|  | const wxString & | label,
|  | const wxPoint & | pos = `wxDefaultPosition`,
|  | const wxSize & | size = `wxDefaultSize`,
|  | long | style = `wxEL_DEFAULT_STYLE`,
|  | const wxString & | name = `wxEditableListBoxNameStr` |
| ) |  |  |

Creates the editable listbox for two-step construction.

See wxEditableListBox() for further details.

void wxEditableListBox::GetStrings | ( | wxArrayString & | strings | ) | const

Returns in the given array the current contents of the control (the array will be erased before control's contents are appended).

void wxEditableListBox::SetStrings | ( | const wxArrayString & | strings | ) |

Replaces current contents with given strings.

|  | [ top ]