A
art
Any Pros out there not mind sharing on how to do this ? The scratch
code here is 80 percent of the job .
Thanks,
Art
Sub hyperlink_invocation()
'
' Launch default hyperlink of the active object on active page
' not sure how to get the default hyper object though.
Dim intCounter As Integer
Dim i As Integer
Dim sel As Selection
Set sel = ActiveWindow.Selection
For intCounter = 0 To sel(1).Hyperlinks.Count - 1
If sel(1).Hyperlinks.Item(intCounter).IsDefaultLink Then
i = 1
sel(1).Hyperlinks.Item(intCounter).Follow
Else
i = 0
End If
Debug.Print intCounter, sel(1).Hyperlinks.Item(intCounter), i
Next intCounter
End Sub
' For the selection add dblclk event to call hyperlink invocation
'
Sub addDblClickBehaviorToSel()
Dim intCounter As Integer
Dim i As Integer
Dim sel As Selection
Set sel = ActiveWindow.Selection
For intCounter = 1 To sel.Count
Debug.Print intCounter, sel(intCounter).Text
'sel(intCounter).CellsSRC(visSectionObject, visRowEvent,
visEvtCellDblClick).FormulaU = "RUNMACRO
(""ThisDocument.hyperlink_invocation"")"
sel(intCounter).Cells("EventDblClick").FormulaU = "RUNMACRO
(""ThisDocument.hyperlink_invocation"")"
Next intCounter
End Sub
code here is 80 percent of the job .
Thanks,
Art
Sub hyperlink_invocation()
'
' Launch default hyperlink of the active object on active page
' not sure how to get the default hyper object though.
Dim intCounter As Integer
Dim i As Integer
Dim sel As Selection
Set sel = ActiveWindow.Selection
For intCounter = 0 To sel(1).Hyperlinks.Count - 1
If sel(1).Hyperlinks.Item(intCounter).IsDefaultLink Then
i = 1
sel(1).Hyperlinks.Item(intCounter).Follow
Else
i = 0
End If
Debug.Print intCounter, sel(1).Hyperlinks.Item(intCounter), i
Next intCounter
End Sub
' For the selection add dblclk event to call hyperlink invocation
'
Sub addDblClickBehaviorToSel()
Dim intCounter As Integer
Dim i As Integer
Dim sel As Selection
Set sel = ActiveWindow.Selection
For intCounter = 1 To sel.Count
Debug.Print intCounter, sel(intCounter).Text
'sel(intCounter).CellsSRC(visSectionObject, visRowEvent,
visEvtCellDblClick).FormulaU = "RUNMACRO
(""ThisDocument.hyperlink_invocation"")"
sel(intCounter).Cells("EventDblClick").FormulaU = "RUNMACRO
(""ThisDocument.hyperlink_invocation"")"
Next intCounter
End Sub