resolveFilePath
R2026bDescription
returns the absolute path to the file or folder specified by absolutePath = resolveFilePath(name)name. The input
can be a file or folder name, a relative path, or a location on the MATLAB® path. If the function does not find the specified file or folder, the output is a
<missing> string.
specifies additional options using one or more name-value arguments. For example, specify
absolutePath = resolveFilePath(name,Name=Value)EntryType="folder" to resolve paths to folders only.
Examples
Input Arguments
Name-Value Arguments
Output Arguments
Tips
Several MATLAB functions provide different resource-lookup capabilities. Choose the function that matches the type of resource you want to find:
If a given input has multiple matches (for example, a file exists both in the current folder and on the MATLAB path), the function returns only the earliest match.
resolveFilePathsearches the current folder first, followed by folders on the MATLAB path.
Version History
Introduced in R2026b