I am getting the following pop up (see error.jpg). I am using the following code to open files on the server, and want to know how to keep it from asking.prompting this every time. Is there a better way to code it to prevent this, or is it unavoidable?
Code:
Private Sub pfp1button_Click()
Dim strLinkUrl As String
Dim strPath As String
Dim strAddr() As String
strPath = "G:/Fire/Private/PDF PFP/"
strLinkUrl = [Pre-Plan #] & ".pdf"
strAddr = Split(strLinkUrl, "", , vbTextCompare)
strLinkUrl = ""
For i = LBound(strAddr()) To UBound(strAddr())
strLinkUrl = strLinkUrl & strAddr(i) & "+"
Next i
strLinkUrl = strPath & Left(strLinkUrl, Len(strLinkUrl) - 1)
Debug.Print strLinkUrl
Me.pfp1button.HyperlinkAddress = strLinkUrl
End Sub
The files are in G:/Fire/Private/PDF PFP/ and every file is named after the Pre-Plan # (ie. A01.pdf, A02.pdf, A03.pdf, etc)