閉じる

ファイルの有無を調べる。 DIR関数


DIR関数



Dim wPASS as string

Dim strFileName as string



wPASS = "c:\temp\*.txt"



strFileName = Dir(wPASS)

'データがない場合は "" が strFileNameに入力される。







Do Until strFileName = ""

  Debug.Print strFileName

  strFileName = Dir(wPASS)

Loop