Default_Path_Retrie​val

버전 1.1.0.0 (4.51 KB) 작성자: Thomas Clark
Save and retrieve last-used path strings. Ideal for users of uigetfile() and similar functions.
다운로드 수: 904
업데이트 날짜: 2009/9/16

라이선스 보기

_________
This function can help if you:
- frequently access/write files/folders which are not necessarily on your MATLAB path

- Do lots of load/save type operations to various different destinations

- Use dialogue functions like uigetfile() and uigetdir()
_________

What it does:
If you have a path string in your current workspace, you can add it to a single database file.

At a later date, use a simple command to retrieve the path for reuse.

The database file is automatically created; there is no need to edit it manually.
_________

How I use it:
I write toolboxes. So in the toolbox I'm currently writing, users load image files, they load calibration files, and they load results files.

Each time uigetfile() is used to locate a file (of a given type), I use these functions to get the directory path of the last-accessed file of the required type. I pass this to the DefaultName input for uigetfile.

Result: The uigetfile() dialogue box goes to the most likely folder in which that file type is stored, instead of starting in the MATLAB current directory.

인용 양식

Thomas Clark (2024). Default_Path_Retrieval (https://www.mathworks.com/matlabcentral/fileexchange/24965-default_path_retrieval), MATLAB Central File Exchange. 검색됨 .

MATLAB 릴리스 호환 정보
개발 환경: R2008a
모든 릴리스와 호환
플랫폼 호환성
Windows macOS Linux
카테고리
Help CenterMATLAB Answers에서 Startup and Shutdown에 대해 자세히 알아보기
도움

받음: M-file Header Template

Community Treasure Hunt

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

Start Hunting!
버전 게시됨 릴리스 정보
1.1.0.0

Update 16 Sept 2009:
- Fixed a permissions related bug (writing to matlabroot) in linux/unix
- Database file is now saved with m-files instead of in matlabroot
- Couple of code-tidiers (e.g. use of dynamic fieldnames)

1.0.0.0