Function fncIsExistsDir(targetPath As String) As Boolean '---------------------------------------------------- '機能:指定されたフォルダパスが存在する '引数1:フォルダパス '戻り値:フォルダの有無をTrueかFalseで返す '----------------------------------------------------- With CreateObject("Scripting.FileSystemObject") If .FolderExists(targetPath) Then fncIsExistsDir = True Else fncIsExistsDir = False End If End With End Function