How to play random song from list box in GUI Matlab?
1 visualizzazione (ultimi 30 giorni)
Mostra commenti meno recenti
Epri Pratiwi
il 4 Ago 2020
Commentato: Epri Pratiwi
il 4 Ago 2020
How to play randomly the selected song from list song box?![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/341068/image.png)
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/341068/image.png)
0 Commenti
Risposta accettata
Walter Roberson
il 4 Ago 2020
songnames = handles.AppropriateListboxName.String;
N = length(songnames);
randomsong = songnames{randi(N)};
and then proceed to play the song.
Più risposte (0)
Vedere anche
Categorie
Scopri di più su Get Started with MATLAB in Help Center e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!