Effacer les filtres
Effacer les filtres

How can I use uigetfile to get the file path?

89 vues (au cours des 30 derniers jours)
Alejandro
Alejandro le 11 Avr 2013
Hello, I was wondering if I could use the function uigetfile to get the complete file path string.

Réponse acceptée

Image Analyst
Image Analyst le 12 Avr 2013
The documentation for uigetfile() is remiss in not showing any examples that use fullfile() to construct the full file name of the chosen file. Here is how you do it:
[baseName, folder] = uigetfile();
fullFileName = fullfile(folder, baseName)
  1 commentaire
Alejandro
Alejandro le 12 Avr 2013
Thank you! I was looking for the full file path and this is it!

Connectez-vous pour commenter.

Plus de réponses (1)

Matt J
Matt J le 12 Avr 2013
The 2nd output argument of uigetfile() gives the path info. See
>>doc uigetfile
  1 commentaire
Jan
Jan le 12 Avr 2013
Exactly. Reading the help and doc text is a good strategy, when you have questions conderning a command.

Connectez-vous pour commenter.

Catégories

En savoir plus sur Adding custom doc dans Help Center et File Exchange

Tags

Aucun tag saisi pour le moment.

Community Treasure Hunt

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

Start Hunting!

Translated by