file クラス : DirectoryName ゲッタ
説明
親ディレクトリの絶対パスを表す文字列を取得します。
構文
fileInstance.DirectoryName
引数
無し。
返り値
| クラス | 説明 |
| string | 親ディレクトリの絶対パス。 |
サンプルコード
| 1: | file f = new file("c:\somewhere..."); |
| 2: | string dirPath = f.DirectoryName; |
注意
これは、System.IO.FileInfo.DirectoryName プロパティのラッパーです。


