How to get the index of a selected row ListBox and pass that onto a new view
13 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
I am loading another .fig on click in a listbox, but I want to get that index that was clicked within the listbox, then pass that on to the new .fig. How would I do this? Thanks
1 Kommentar
Antworten (1)
Image Analyst
am 22 Mai 2013
% Get the item selected in listbox1 of fig1:
selectedItem = get(handles.listbox1, 'value');
% Now send it to the second function
% Call fig2 and pass it selectedItem via the input argument list.
output2 = fig2(selectedItem);
1 Kommentar
Siehe auch
Kategorien
Mehr zu Specifying Target for Graphics Output finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!