This article looks at an alternative method to get a link to that Livelink Object. For this we will use the Livelink URL that is used by the Notifications system (<Livelink URL>?func=notify.config).
function String getDefaultURL (DAPINode inNode) // Load the Notification Configuration information Dynamic config=$LLAgent.Utils.ConfigLoad( prgCtx.USession().fDbConnect.fConnection, 100 ) // Convert the Node into a WebNode Object webNode=$WebNode.WebNodes.GetItem(inNode.pSubType) // Get the Open action of the WebNode Object open=webNode.Cmd("open") // String to store the return value String nodeURL // if the Object in question is a Document then point at the General Properties page if (inNode.pSubType == $TypeDocument) nodeURL=Str.Format("%1?func=ll&objid=%2&objaction=properties",config.URL,inNode.pID) // Otherwise, use the default Open command URL else nodeURL=Str.Format("%1?%2",config.URL,Str.Format(open.fQueryString,inNode.pID)) end endIn response to a question on the Knowledge Center, another approach for creating the nodeURL was provided by Kyle Swidrovich. This approach would replace the if .. then clause in the function with the following :
nodeURL = Str.Format("%1/open/%2", config.URL, inNode.pID)Having tested this approach, the only difference I've found is that the original code takes you to the browse page for Folders, Projects, Compound Documents etc and the Properties page for Documents, whereas the new one just calls the open action for that Object. Thus if a Document is a Word document it would be viewed - or you would see the Document Overview page depending on your configuration - and a ZIP file would be downloaded rather than showing the Properties dialog for the Object, in some cases this may be what you want.