drom
Well-known Member
- Joined
- Mar 20, 2005
- Messages
- 543
- Office Version
- 2021
- 2019
- 2016
- 2013
- 2011
- 2010
- 2007
Hi and thanks in advance!!
I have this Macro:
Is any way of knowing if I am gonna get err <> 0 without using:
So I Would like to know if I can Check if I am gonna get the Err Message without opening the file
So If the File exists (No ERR) Good but but:
Otherwise Get the Message
Sometimes the File are gonna be on a PC like:
PS:
I fthe file is in a PC, I know how to act (D: X: E: etc...)
I have this Macro:
VBA Code:
Sub Macro1()
On Error Resume Next
Dim wCell As String: wCell = ActiveCell
ThisWorkbook.FollowHyperlink (wCell)
If Err <> 0 Then
Debug.Print Err, Err.Description
End If
End Sub
Is any way of knowing if I am gonna get err <> 0 without using:
ThisWorkbook.FollowHyperlink (wCell)
Sometimes the Link is gonna be in a Shared folder and the File Address is gonna be something like:Invoices%20VISADAS%202024/Week%2021/OLIVAR%20EL%20frfrss-%2024A001894%20ABC.pdf
So I Would like to know if I can Check if I am gonna get the Err Message without opening the file
So If the File exists (No ERR) Good but but:
Otherwise Get the Message
Sometimes the File are gonna be on a PC like:
- D:\ExcelFiless\aaaaaaaaaaaaaaaaPendingJOBS\20ABC.PDF
- X:\File___0001abc.PDF
- E:\Filess\AAA___0001abc.PDF
PS:
I fthe file is in a PC, I know how to act (D: X: E: etc...)