how to change the displayed filename
Afficher commentaires plus anciens
I tried making a GUI where MatLab runs a script on a directory from a certain path, when showing the directory being used is there any way to show just the file name excluding the path i.e. *.ds, and when showing where the file is being saved, and what the path is to get the file, is there any way to show just the path excluding the file name i.e. D1/D2/D3 without the *.ds
Réponses (1)
Image Analyst
le 3 Juil 2013
1 vote
Use the fileparts() function to get the parts of the filename. Use sprintf() to build up any string that you want to display, and use set() to send that string to any static text or other control on your GUI.
Catégories
En savoir plus sur Search Path dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!