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

조회 수: 2 (최근 30일)
InfoImage = imfinfo(filename);
imgName = InfoImage.Filename;
app.FileNameEditField.Value = [imgName];
Thank you for your help.

채택된 답변

Walter Roberson
Walter Roberson 2022년 12월 2일
[~, imgName, extension] = fileparts(InfoImage.Filename);
Then use either imgName alone or [imgName, extension] if you want to preserve the extension.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Develop Apps Using App Designer에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by