cancel
Showing results for 
Search instead for 
Did you mean: 

How to get the folder Id

nihar
Champ in-the-making
Champ in-the-making
Hi , I am new to alfresco ,


I am having a site called sample , I want to know how to get the folder id of DOCUMENT LIBRARY.

Thank You,
Nihar Narla
1 REPLY 1

rjohnson
Star Contributor
Star Contributor
If by folder id you mean nodeRef (you might mean dbid), then in Javascript running in the repository layer (Alfresco) you would call:-


var folderObject = companyhome.childByNamePath("/Sites/{your-site-short-name}/documentLibrary");


Should return you the object which has a property nodeRef (folderObject.nodeRef) and the dbid (folderObject.properties["sys:dbid"])

Good luck

Bob Johnson