Effacer les filtres
Effacer les filtres

Hi, how should I display the name for image. Only Name without the pathways.

2 vues (au cours des 30 derniers jours)
InfoImage = imfinfo(filename);
imgName = InfoImage.Filename;
app.FileNameEditField.Value = [imgName];
Thank you for your help.

Réponse acceptée

Walter Roberson
Walter Roberson le 2 Déc 2022
[~, imgName, extension] = fileparts(InfoImage.Filename);
Then use either imgName alone or [imgName, extension] if you want to preserve the extension.

Plus de réponses (0)

Catégories

En savoir plus sur Develop Apps Using App Designer dans Help Center et File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by