Documentation

我们为许可用户提供了部分翻译好的中文文档。您只需登录便可查阅这些文档

restoredefaultpath

Restore search path to its factory-installed state

Alternatives

As an alternative to the restoredefaultpath function, use the rmpath function or use the pathtool function to open the Set Path dialog box.

Syntax

restoredefaultpath

Description

restoredefaultpath restores the MATLAB® search path to its factory-installed state.

    Note:   restoredefaultpath is intended only for situations where MATLAB is experiencing startup problems due to a corrupt search path. For general search-path cleanup, use the rmpath function or the Set Path dialog box.

If MATLAB fails to initialize properly on startup, then call both restoredefaultpath and matlabrc. For more details, see Path Unsuccessfully Set at Startup.

MATLAB does not support issuing restoredefaultpath from a UNC path name. Doing so might result in MATLAB being unable to find files on the search path. If you do use restoredefaultpath from a UNC path name, restore the expected behavior by changing the current folder to an absolute path, and then reissuing the restoredefaultpath command.

Introduced before R2006a

Was this topic helpful?