This is a re-post of this here (WEBB9B7LTR by Sep. 3, 2013, for Notes 8.5.3 - sorry for DocLink ) due to this very same issue is also present in Notes 9.01 (Wintel, at least)
Hi there
Looking at the HotSpot definition @ IBM's Notes 8.5.1 Help here:
http://publib.boulder.ibm.com/infocenter/domhelp/v8r0/index.jsp?topic=%2Fcom.ibm.designer.domino.main.doc%2FLSAZ_USING_LS2J_MIDTOPIC_227115017629463475.html
a number of UI-objects seems to map into a HotSpot:- A link hotspot
- A text pop-up
- A button
- A formula pop-up
- An action hotspot
However, I have a RT field, in which I have defined a Link hotspot, and even so, the code I have to parse this (saved backend) document, tells me there is no HotSpot !
I wonder if there's a lag in the hotspot definitions somewhere ?
Has anyone dealt with this ?
From Designer Help (several places) is says also a "DocLink, with a NULL (rtlink.HotSpotText = "") HotSpotText is not a HotSpot.".
This seems not entirely true, since my debug code shows 0 DocLinks, and yet I do have a HotSpots !
Here's my Debug button code from the Designer Help (8.5.3) in my form, slightly adapted to my actual field:
Sub Click(Source As Button)
' Helper Code from Notes Designer help and re-fitted to a button
' Dim session As NotesSession
Dim workspace As New NotesUIworkspace
Dim db As NotesDatabase
' Dim dc As NotesDocumentCollection
Dim doc As NotesDocument
Dim rti As NotesRichTextItem
Dim rtnav As NotesRichTextNavigator
' Set session = New NotesSession
' Set db = session.CurrentDatabase
'Set dc = db.UnprocessedDocuments
'Set doc = dc.GetFirstDocument
Set uidoc = workspace.CurrentDocument
Set rti = uidoc.document.GetFirstItem("LocationofPD")
Set rtnav = rti.CreateNavigator
Messagebox "Number of doc links = " & GetCount(rtnav, RTELEM_TYPE_DOCLINK) _
& Chr(13) & _
"Number of file attachments = " & GetCount(rtnav, RTELEM_TYPE_FILEATTACHMENT) _
& Chr(13) & _
"Number of OLE objects = " & GetCount(rtnav, RTELEM_TYPE_OLE) _
& Chr(13) & _
"Number of sections = " & GetCount(rtnav, RTELEM_TYPE_SECTION) _
& Chr(13) & _
"Number of tables = " & GetCount(rtnav, RTELEM_TYPE_TABLE) _
& Chr(13) & _
"Number of table cells = " & GetCount(rtnav, RTELEM_TYPE_TABLECELL) _
& Chr(13) & _
"Number of text paragraphs = " & GetCount(rtnav, RTELEM_TYPE_TEXTPARAGRAPH) _
& Chr(13) & _
"Number of text runs = " & GetCount(rtnav, RTELEM_TYPE_TEXTRUN),, _
"Elements in LocationofPD item"
End Sub
Function GetCount(rtnav As NotesRichTextNavigator, elementType As Integer) As Integer
GetCount = 0
If rtnav.FindFirstElement(elementType) Then
Do
GetCount = GetCount + 1
Loop While rtnav.FindNextElement(elementType)
End If
End Function