You need to sign in to do that
Don't have an account?
narender.gupta01
How to create folder programmatically?
Hi,
I'm trying to create a folder programmatically, but it's showing a save Error: DML not allowed on Folder.
I read somewhere that you can "create a folder in SFDC via setup". (http://boards.developerforce.com/t5/Apex-Code-Development/Creating-folders-using-apex/m-p/383265#M68616)
I couldn't find any help / documentation on that. Please help me on how can I do that. Any pointers / code will be highly appreciated.
Thanks
Narender
Creating a folder via setup means doing it using the salesforce UI and not Apex. Apex cannot create folders for you, it is simply not allowed.
Go to Documents Tab and there you'll have a 'Create a New Folder' option, that's where you can create your folders from using Setup.