I'm having issues getting this to work.. Always comes back "it doesn't exist"
If Sheets("Panel").Cells(X, 6).Value = "Yes" Then
'=============================================
' PDF them
'=============================================
Sheets("Panel").Visible = False
If Sheets("Panel").Cells(X, 22).Value = "Published" Then
filepathname = Sheets("Panel").Cells(X, 24).Value
Else
filepathname = Sheets("Panel").Cells(X, 23).Value
End If
'Build Path
FileCheckPath = filepathname & Sheets("Panel").Cells(X, 20).Value
filepathname = filepathname & Sheets("Panel").Cells(X, 20).Value & "\" & Sheets("Panel").Cells(X, 25).Value & "_PMP"
'Add date if it is requested
If Sheets("Panel").Cells(X, 21).Value = "Yes" Then
filepathname = filepathname & "_" & Month(Now()) & "-" & Day(Now()) & "-" & Year(Now())
End If
'Add file extension ;0)
filepathname = filepathname & ".pdf"
'Does directory exist?
MsgBox (FileCheckPath)
If Dir(FileCheckPath, vbDirectory) = "" Then
MsgBox ("it doesn't exist")
Else
MsgBox ("it does exist")
End If
Sheets("Panel").Visible = True
Sheets("Panel").Activate
'=============================================
End If
Never mind! Built the path wrong..
Bookmarks