Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at

  • Andy 13 posts 54 karma points
    Apr 01, 2020 @ 08:34

    How to create a custom document type from code?

    Hi all,

    So i'm brand new to umbraco and very excited to be using it. I've completed the online getting started tutorial that Umbraco provide and now i'm looking to delve a little deeper.

    Trying to understand how to create a custom document type from code, rather than use the out of the box feature's id like to know how to create my own.

    Can someone provide some info / a link to how I might go about this? I'm certain there is stuff out there but I can't seem to find it! I'm still new so i'm probably not looking in the right place!


  • David Brendel 786 posts 2952 karma points MVP c-trib
    Apr 02, 2020 @ 14:43
    David Brendel

    Hi Andy,

    in Umbraco you usually don't create DocumentTypes by Code. You are using the UI in the CMS.

    There is a IContentTypeService which you can inject into your controller/class and use.

    But when you are trying to create your site structure then as said use the UI.

    Regards David

Please Sign in or register to post replies

Write your reply to: