opening a fig in different directory

hi. I have two .fig files: for example fig1 and fig2. fig2 is in a folder for example folderfig2. this folder is beside fig1. I want to open fig2 by clicking a push button in fig1. I should make this program exe so it dosnt have specified directory. what should I do?

 Réponse acceptée

Azzi Abdelmalek
Azzi Abdelmalek le 3 Août 2013
When you want to use any file you have to specify the name of the file and its location. example
folder='E:\matlab'
filename='fig1.fig'
ful_file=fullfile(folder,filename)
Then use ful_file

Plus de réponses (0)

Catégories

En savoir plus sur File Operations dans Centre d'aide et File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by