handling filename containing spaces
Mostrar comentarios más antiguos
I am using the following code to load a data file [Windows environment]:
FileName = uigetfile('*.TAB','Select a TAB file.');
Frames = dlmread(FileName_in,'\t');
Most of the files have names such as foo_two.tab or foo-two.tab Some contain spaces, such as foo two.tab
I have tried both strcat and regexp to insert single quotes at the beginning and end of the filename string but these are ignored by the dlmread function.
Any tips or suggestions would be appreciated.
1 comentario
Sean de Wolski
el 16 de Mzo. de 2012
So I take it that doesn't work as written?
Respuesta aceptada
Más respuestas (1)
Sean de Wolski
el 16 de Mzo. de 2012
1 voto
Ahh!
Difference between FileName and FileName_in. The issue has nothing to do with spaces.
1 comentario
Philip
el 16 de Mzo. de 2012
Categorías
Más información sobre Characters and Strings en Centro de ayuda y File Exchange.
Productos
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!