Saving a figure in GUI

4 次查看(过去 30 天)
Subhiksha
Subhiksha 2013-9-3
On executing some GUI code i am getting a figure.If the user closes the image he/she is asked whether he/she needs to save the image. if the user answers as yes i should save the image in user selected location.How to do this.
Please help
Thanks in advance

回答(1 个)

ES
ES 2013-9-3
get the handle of the figure and do a saveas call.
eg: saveas(h,'filename','format')
format can be any image format or pdf etc.

类别

Help CenterFile Exchange 中查找有关 Environment and Settings 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by