How to set a path for saving file?
조회 수: 7 (최근 30일)
이전 댓글 표시
Hi guys,
Working on my PC I can save an output file.xls in an existing directory called 'output' through the commands:
path_out=['F:\Code\output\'];
file_out=[path_out,'file.xls'];
xlswrite(file_out);
Working on another PC it will give an error (directory not found)? Do I have to change every time the path_out? Is there a more efficient way to find the directory 'output'?
Thanks an advance!
댓글 수: 0
답변 (1개)
Sean de Wolski
2014년 12월 18일
Some friends
doc pwd % present working directory
doc fullfile % build a full file path
doc uiputfile % let the user choose!
댓글 수: 0
참고 항목
카테고리
Help Center 및 File Exchange에서 File Operations에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!