Quantcast
Channel: SharePoint 2010 - Development and Programming forum
Viewing all articles
Browse latest Browse all 11571

Can I add Custom Content Type created programmatically to Custom List Definition?

$
0
0

I have created Custom content type programmatically in the Feature Receiver. Followed by this have another feature which creates List Template. I want to add the custom content type to the list template.

Using VS 2012, I added the custom content type to the list definition. The Schema.xml for the list definition looks as below:

<ContentTypes><ContentTypeRef ID="0x010100D7D9F4B1F4A9684BB44389571024B2EC00C393BB21B8AD7B41B62A87DF0501504D" /></ContentTypes>

ID was automatically added by the VS tool.

List Template is created, the new content Type is also added, but the Name is displayed as "Document" instead of the custom content type name. So I see two CTs with the name "Document".

How can I achieve this? Any help is appreciated.

 



Viewing all articles
Browse latest Browse all 11571

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>