IRootLab
An Open-Source MATLAB toolbox for vibrational biospectroscopy
listbox_get_selected_names.m
Go to the documentation of this file.
1 %>@ingroup misc
2 %>@file
3 %>@brief Returns the selected elements of a listbox or popupmenu as a cell of strings
4 
5 function a = listbox_get_selected_names(h_listbox)
6 a = get(h_listbox, 'String');
7 if ~isempty(a)
8  if length(a) == 1 && ismember(a{1}, {'(none)', '(leave blank)'})
9  a = {};
10  else
11  ii = get(h_listbox, 'Value');
12  a = a(ii);
13  end;
14 end;
function listbox_get_selected_names(in h_listbox)
Analysis Session (AS) base class.
Definition: as.m:6