just wondering if you can help I'm only just starting with SharePoint Development

I have a request for some c# code that will allow users to do the following:

Within a specific Site Collection e.g. HR then document library named Personnel click on a New Content Type Button that does the following. 1. Prompts for a new folder name (bloggs, joe) 2. Creates a specific set of sub folders

Seems simple enough but all of the articles/blogs I've come across are incomplete or are so poorly structured it's like trying to decipher hieroglyphics

1 Answer 1


You can create a Ribbon button, call a layouts page as a Pop up page and pass it the ListID. The layouts page will contain a textbox where you can input folder and subfolder names separated by a separator like comma. It will also have a button and clicking on button will create folders in the list. The example here shows how to Invoke server side code on SharePoint ribbon click using SharePoint Page dialog

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.