How to get the name of the mat file saved from the uisave function?

2 visualizaciones (últimos 30 días)
I am going to write a GUI based program. The workspace data-set needs to be saved as a Project file. In fact, I want to design some buttons named 'Save' , 'Save as' and 'Load'. Anyone can help me to write its code suitably?. I need to know the name and address of the file that has been saved from uisave function.

Respuesta aceptada

Jan
Jan el 8 de Oct. de 2016
Editada: Jan el 8 de Oct. de 2016
Do not use uisave but:
[filename, filepath] = uiputfile('*.mat', 'Save the project file:')
if isequal(filename,0) || isequal(pathname,0)
disp('User pressed cancel')
return;
end
FileName = fullfile(pathname, filename);
save(FileName, 'YourData');

Más respuestas (0)

Etiquetas

Community Treasure Hunt

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

Start Hunting!

Translated by