I am creating a custom field type, Content type and List definition. I have a custom field type inheriting from Multicolumn value and I am adding new fields of my custom type to my new listdefinition.For this I have following files.

For Custom field type

1.  .cs file
2.  .xml file
3.  .ascx file
4.  .xsl file

For List definition

5.  Element.xml
6.  Schema.xml

I am adding a content type in my element.xml file and adding the fields to my new list definition through schema.xml

When I am deploying this, what is the order in which above files are invoked? Which created first, custom field type? Content type?Fields? List definition?

1 Answer 1


Your .cs, .ascx, .xml and .xsl files are only invoked when rendering the field, and each time the field is shown on forms & list views.

The contents of the elements file will reference something in the Schema file, so the schema file is loaded first before the contents of the elements, and this is done only on Feature activation.

For the rest, the general order is always this:

Field Definitions Content Type Definitions List Definitions List Instances

All the contents of all Elements.xml files are parsed and loaded at once into the content database, which orders them according to a specific schema, and creates the appropriate artefacts. This all happens on Feature Activation.

  • inside schema.xml we add/reference content types and add fields in content types to list definition in schema.xml.So if schema.xml loads first then how will we get custom content types in schema.xml?
    – anish
    Oct 26, 2013 at 4:57
  • You said that ,For the rest, the general order is always this: "Field Definitions Content Type Definitions List Definitions List Instances".Then custom content types comes first in the order?
    – anish
    Oct 26, 2013 at 4:57
  • As long as the dependant artefacts are all installed with the same Feature, then SharePoint will analyse all the artefacts available and load the correct dependencies as it needs them. The only "order" you need to worry about in the true sense is that things you need (Fields, Content Types) already exist, or are declared in the same Feature.
    – James Love
    Oct 26, 2013 at 21:57

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.