function str = popupstr(handle)
%POPUPSTR Get popup menu selection string.
%  STR = POPUPSTR(H) returns the currently selected string
%  for the popup menu uicontrol whose handle is H.

%  Steven L. Eddins, April 1994
%  Copyright (c) 1984-98 by The MathWorks, Inc.
%  $Revision: 1.7 $  $Date: 1997/11/21 23:49:10 $

pick_list = get(handle, 'String');
selection = get(handle, 'Value');
if (iscell(pick_list))
    str = pick_list{selection};
else
    str = deblank(pick_list(selection,:));
end

