Search DXM Forum
I'm looking for a way to extend the event handler that gets called when a folder is created (inside the content tree) so I can run validation. I also need a way to display a message to the user depending on the validation outcome. Is there a way to do this?
You cannot run code on a folder specifically. However you can create folder using a model that has a default page i.e. index or default and put code in new.aspx for the template for that page and that code can run upon creation. For validation you can either place content in the asset or even email the user using Util.Email.
--
## If I’ve helped, accept this response as a solution so that other’s can find is more quickly in the future.
## Have thoughts on Crownpeak products? We'd love to hear them. Speak with the Crownpeak Product Team..
You cannot run code on a folder specifically. However you can create folder using a model that has a default page i.e. index or default and put code in new.aspx for the template for that page and that code can run upon creation. For validation you can either place content in the asset or even email the user using Util.Email.
--
## If I’ve helped, accept this response as a solution so that other’s can find is more quickly in the future.
## Have thoughts on Crownpeak products? We'd love to hear them. Speak with the Crownpeak Product Team..
Thanks for the reply Kensnyder. Your work-around is not not ideal for my use case but it's good to know.