Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
THRUST SERVICES & TOOLS
CLOUD EDITIONS
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Content Management (Extended ECM)
API, SDK, REST and Web Services
Getting All Object Types and Whether it is a container
Chip_Beaulieu_(beauliec_-_(deleted))
In LAPI, for each object I point to in Livelink, I want to know:1. Is the object a container object (e.g. Folder, Project..)2. What is the icon used for the project.Does anyone know how to get this info from LAPI? I could hard code it, but that is not a great solution.
Find more posts tagged with
Comments
Dave_Sawyer_(dsawyer_(Delete)_2254029)
I would also like to know about how to get the Icon for a specific file type from Livelink ...In Visual Basic I can answer the first one ... although after six months you may already have an answer:1. Is the object a container object?Once you have a list of objects from LL_ListObjects you can get the type of each object by calling LL_TableGetInteger(
, , "SubType", ). You can compare the value to the LL constants defined in the lapi_documents.bas file.Here is a routine that will return the SubType in a string:Public Function GetLLObjectType(ByVal LLType As Long) As String Select Case LLType Case LL_FOLDERSUBTYPE, LL_STANDARDSUBTYPE: GetLLObjectType = "Folder" Case LL_DOCUMENTSUBTYPE: GetLLObjectType = "Document" Case LL_WORKFLOWMAPSUBTYPE: GetLLObjectType = "Workflow Map" Case LL_QUERYSUBTYPE: GetLLObjectType = "Query" Case LL_COMPOUNDDOCUMENTSUBTYPE: GetLLObjectType = "Compound Document" Case LL_URLSUBTYPE: GetLLObjectType = "URL" Case LL_PROJECTSUBTYPE: GetLLObjectType = "Project" Case LL_DISCUSSIONSUBTYPE: GetLLObjectType = "Discussion" Case LL_TOPICSUBTYPE: GetLLObjectType = "Topic" Case LL_REPLYSUBTYPE: GetLLObjectType = "Reply" Case LL_CHANNELSUBTYPE: GetLLObjectType = "Channel" Case LL_NEWSSUBTYPE: GetLLObjectType = "News" Case LL_TASKSUBTYPE: GetLLObjectType = "Task" Case LL_TASKLISTSUBTYPE: GetLLObjectType = "Task List" Case Else: GetLLObjectType = "" End SelectEnd Function
Chip_Beaulieu_(beauliec_-_(deleted))
Support told me that you cannot get the icon for a file type from LAPI.Thanks for the answer to the other question. This is what I ended up doing, but I always hate to hard code things. What if I create a new item type in Livelink? Then I have to go back to the code and explicitly tell it about the new item type.Best regards,Chip Beaulieu.