I keep getting a 400 error when running the code below. This only happens if the code goes to error handler and is then repeated immediately after. Any ideas why?
Public Sub OpenDrawing()
StopVLookup = True
Dim partno As String
On Error GoTo errorhandler
partno = Cells(ActiveCell.row, 1)
ActiveWorkbook.FollowHyperlink "\\192.168.1.202\MechDesign\All RoBAT Drawings\" & partno & ".pdf"
StopVLookup = False
Exit Sub
errorhandler:
MsgBox "Can't Find Drawing"
StopVLookup = False
End Sub
Public Sub OpenDrawing()
StopVLookup = True
Dim partno As String
On Error GoTo errorhandler
partno = Cells(ActiveCell.row, 1)
ActiveWorkbook.FollowHyperlink "\\192.168.1.202\MechDesign\All RoBAT Drawings\" & partno & ".pdf"
StopVLookup = False
Exit Sub
errorhandler:
MsgBox "Can't Find Drawing"
StopVLookup = False
End Sub