You need to sign in to do that
Don't have an account?
MattMet86
Create ContentFolder in library
Anybody know how to create a content folder? I have tried this command via the execute annonoymous window but I am getting back an incorrect ID for the parentContentFolderID field. My ID is the chatter library ID.
List<ContentFolder> folder = new List<ContentFolder>(); folder.add(new ContentFolder( Name = 'HR Buzz', ParentContentFolderId = '05880000000PvIv' )); insert folder;
So you easy can use that code to create new one!
But if you need to create hierarchy of folders you need to use already existed Record id.
Something like this.
or https://developer.salesforce.com/docs/atlas.en-us.api.meta/api/sforce_api_objects_contentfolder.htm
Please Mark my post as best answer if that helps you!
Thanks!