FindFile
詳細
- FindFile[name]は指定名のファイルを求め,$Pathで与えられる各ディレクトリ内を順次検索する.
- FindFileは完全な絶対ファイル名を返す.
- 指定名のファイルが見付からない場合,FindFileは$Failedを返す.
- FindFile[name]では,ファイル名は/パスセパレータ(Windows上では\\)を用いて指定できる.コンテキストセパレータの`を用いて指定することもできる.
- "name`"形式の名前について,FindFileは"name.mx"と"name.m"のファイルを検索する.
- ディレクトリに行き着いた場合,FindFileはそのディレクトリ内のKernel/init.m または init.m のような名前のファイルを探す.
- ディレクトリに相当する"name.mx"形式のオブジェクトに行き着いた場合,FindFileはname.mx/$SystemID/name.mxのような名前を探す.
- Get,Needs,OpenRead,Installその他の関数は事実上FindFileを使って読込むファイルを検索する.
- FindFile[File["file"]]もサポートされている.
関連項目
FileNames FileNameSetter FileExistsQ SystemDialogInput $Path Get Needs Install NotebookDirectory $Input $InputFileName
Function Repository: ObjectIfExists
関連するガイド
-
▪
- ファイル操作 ▪
- ディレクトリとその操作 ▪
- ファイル名の操作
テキスト
Wolfram Research (2008), FindFile, Wolfram言語関数, https://reference.wolfram.com/language/ref/FindFile.html (2016年に更新).
CMS
Wolfram Language. 2008. "FindFile." Wolfram Language & System Documentation Center. Wolfram Research. Last Modified 2016. https://reference.wolfram.com/language/ref/FindFile.html.
APA
Wolfram Language. (2008). FindFile. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/FindFile.html
BibTeX
@misc{reference.wolfram_2025_findfile, author="Wolfram Research", title="{FindFile}", year="2016", howpublished="\url{https://reference.wolfram.com/language/ref/FindFile.html}", note=[Accessed: 01-May-2026]}
BibLaTeX
@online{reference.wolfram_2025_findfile, organization={Wolfram Research}, title={FindFile}, year={2016}, url={https://reference.wolfram.com/language/ref/FindFile.html}, note=[Accessed: 01-May-2026]}