.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
Gaurav Pal
Post New Web Links

List Definition Guid

Posted By:      Posted Date: October 22, 2010    Points: 0   Category :SharePoint


I'm creating a list definition and instance in VS2010 for deployment and set the guid in the List element of the schema.xml file.

<List Id="{guid}"

After this has been deployed successfully I've looked at the list in designer and the guid is something completely different. 

According to MSDN ...

Optional GUID. Specifies the GUID of the list.

What's going on?

As a secondary question.  What's the best way to package up site pages?

View Complete Post

More Related Resource Links

Issue with List Definition of same base content type and deployed via same feature


I am trying to deploy two custom list definitions using only one single feature.  Below are the details of my issue.

  • Two custom list definitions
  • Each custom list definition has its own custom content type
  • Each custom content type inherits from the base content type Picture (Type = 109)
  • The custom list definitions are grouped together under one single feature
  • The custom content types are grouped together under a seperate single feature

When I deploy my solution in this configuration, the second list definition gets the first custom content type applied to it and the list schema from the first list definition is also applied to the second list definition.

What makes this more interesting, when I seperate both of the list definitions under two seperate features it all works fine.  Custom content types and list schemas get applied correctly.

Can anyone tell me why I can not deploy both list definitions under one single feature?

If you need me to post any of the origional code or XML to this post please let me know.



Invalid data has been used to update the list Item.(List definition)

<nativehr>0x80070057</nativehr><nativestack></nativestack>Invalid data has been used to update the list item. The field you are trying to update may be read only. I have created a list definition and into that i have created lookup column when i am trying to add any item into the list then it gives me an error as above. Can anyone help me.? I made the readonly attributes to false for lookup columns.  

InfoPath list definition of type Document Library

Is there a way to create a list definition that is a document Library and deploy to SharePoint 2010 that is based on a InfoPath form?  Meaning that it will deploy and if I select the "add new item" link it will automatically open a new InfoPath form that a user can submit?  I have the infopath forms created already but I need a way to create the form library through visual studio so I can promote through our test and production environment and have it automatically and deploy to the different environments and create the proper list structure. 

Can not select Forms Library for List Definition

Why can I not select a content type of Forms Library when creating a new List definition?  I want to create a form library list definition that I can link to a InfoPath form that I have created?

Create a list definition without a Custom Content Type

is it possible to create a list definition without creating a custom content type?  I want to create a list definition and select "Custom List" and then I just want to add fields to the custom list and not create a content type that will show up in the SharePoint GUI.  Seems like to get the new fields to show up in the new and edit forms I have to add the fields to a custom content type.

How can I remove/hide built-in Title field in list definition

Now I'm customize a new Content and then new List Template, just like below definition;  <ContentType ID="0x0100ed096ab35eeb4d2e98fb71b9842e9616" Name="Staff Member" Group="Berry Gardens Internet">  <FieldRefs>   <FieldRef ID="{fa564e0f-0c70-4ab9-b863-0177e6ddd247}" Name="Title" />   <FieldRef ID="{F5E777EA-C083-4c2f-BC10-E4BF2B4D6372}" Name="Synopsis" />   <FieldRef ID="{2307576C-A060-4c2d-BABC-34E5A9924667}" Name="Image" />   <FieldRef ID="{051B830A-8105-4384-9AA1-103CEE43B760}" Name="Email Address" />  </FieldRefs> </ContentType> It is inherit from Item parent type, and using built-in Title field({fa564e0f-0c70-4ab9-b863-0177e6ddd247}), but I found that it's diffcult to remove/hide it. When in the default list view, there are two Title fields. So what can I do in the list definition. Regards upzone    

WSPBuilder only including dll, not including list definition files etc


Hi All,

I have a project that contains:

2 Content Types

2 List Definitions

2 List Instances

Event Receivers for 1 List

Have grouped the List Instances and Definitions, so in my WSP View I have 3 features



   Event Receivers


Now, when I build the wsp through VS 2008, it only includes the dll, it doesn't include any other files. So on deployment, none of my features get installed.

Any ideas?



Andrew Berry - Software analyst/Developer

Creating a Custom List Definition that uses InfoPath Form



I have created a custom list definition in Visual Studio 2010.  By default it is using the out of the box "pages\form.aspx" for the New/Edit/Display form rendering. 

I am just wondering if it is possible to use an InfoPath form as default for the New/Edit/Display form?

I have tried to create a custom list with custom info path form thru the UI, and export the site as WSP.  I have analysed the files and notice a few things:

1.) I need to add a XmlDocument section in the Schema.xml for displayifs/editifs/newifs.aspx

2.) I need to provision the xsn in "Lists/{List Name}/Item"

3.) I need to provision the *ifs.aspx in "Lists/{List Name}/Item"

As you see, some of the settings required the {List Name}.  That's mean I can't really create a list definition that is reusable because I need to know the List Name before hand. Is there any way to specify the path with some kind of variable instead of static list name?

Furthermore, I notice that the "Developer" tab is missing from the Ribbon when I modify form, hence I can do any code behind.  Is this a limitation, or is there a workaround?



Wilson | SharePoint Egg's Blog

List Definition & List Instance



I'm trying to deploy a new list definition and with it a new instance of that list. Unfortunately this doesn't work completely. I just wanted to create a new list with some field without any content types.

In schema.xml I did the following changes in the Fields node:

<Field ID="{64E1AAB3-C232-42A5-AAA9-2819AE762044}" Name="test" DisplayName="test" Type="Text"></Field>

And under ViewField

Basic List Definition steps - cannot get columns to show up in New, Edit, etc.


Can someplease explain (since the MSDN docs don't) all the necessary stuff required to make a custom List Definition?  I'm trying to make a List Definition and in the schema.xml I've added some custom columns, as well as existing site columns, and I cannot get anything but the default items (from VS creation itself), like Title, to show up.  Some things I've tried:

1 - Yes, "ShowInNewForm", "ShowInEditForm", and "ShowInDisplayForm" are all set to True

2 - I've tried making an inline Content Type for these new columns (i.e., not a new ContentType element, just inside the Schemal.xml file)

I cannot ever get the custom columns to ever appear on anything other than a View.  Also, how the heck do you hide/get rid of the Title column if you don't need that?


Adding custom list to site definition


Hello All:

First I will explain what I was trying to achieve.

I wanted to create a site definition or site template with some common features e.g. document library with custom columns and then create many sub sites using that template or site definition.

But the idea is that once all the sites have been created and up and running, if it is required in future to modify the document library to either add or remove some columns then I will simply modify the template/site definition and then apply it globally and all the sites will get updated automatically which were created using that template/definition.

I discovered that I can not get it done using site templates as they are just snap shot of sites and any modifcation can only be applied to new sites created based on template not the ones which were already created.

So, if I go with Site Definition option, what is the best way to do it. Create a custom document library and then create list template based on that and then add it on site definition ?

Or create a feature and do it via code in feature activation.?

Or perhaps there is another better way to do it?

Any help is appreciated



SharePoint Developer

Best method for creating a site definition containing a custom list instance



I want to create a new site definition which, when provisioned, includes an instance of a custom list. The custom list definition is contained in a feature as part of the site definition project. What's the best method for creating an instance of this custom list?

I can think of a few ways to do it:

- Modify the onet.xml for my site definition to include an instance of the list

- Use feature stapling to enable my custom list defintion feature when a site is provisioned using my new site definition and include a list instance in the feature.

Is there another more suitable method?



Content Type and List Definition


I created a content type using Site UI named "ContentTypeA"

I added a column named "ColA" to ContentTypeA.

In VS 2010, I created a new List Definition

Under Schema.xml .. I added the "ContentTypeA" GUID. (I got the GUID by open the Content Type in SharePoint Designer)

Under Schema.xml I also added "Field" for "ColA"

Then I deployed the solution.


It created a ListInstance for me named "MyList" but when I select List Settings.. I don't see "ContentTypeA" rather I see "MyList" under ContentType.


Do you know what I am doing wrong?

Customizing AllItems.aspx in List definition project


Hi to all,

I'm creating List definition project in VS 2008. I want to customize allitems.aspx.

I'm planning to create a view similar  like the view I can create with sharepoint designer, but I want to deploy it with my list definition.

Anyone knows some good walk through or article? Or any tip at all?

Custom Discussion Board List Definition in SharePoint 2010


Hi All,

I have created a custom discussion list definition using Visual Studio 2010 in SharePoint 2010. I had an issue, since by default, Visual Studio creates the custom discussion list definition as custom list. So, I have modified the my own Schema.xml with the standard SharePoint discussion Schema.xml by adding views section.

After deploying successfully, when i looked at the Threaded view, it gives a javascript error. I cannot open "Show Quoted Messages" link.

Could anybody face this problem? Please suggest on how to resolve this issue.


Chandrasekaran C N

How to set the order of custom fields in custom list definition of Multiple Content Types


Hi all,

First of all I am sorry for my poor english.

I have a custom list definition and I have mentioned two content types in the "Schema.xml" file of this list. I need to change the order of fields in NewForm.aspx and EditForm.aspx.

For e.g. I have two content types ContentType1 and ContentType2. ContentType2 is inheriting ContentType1.

Fields of ContentType1 are

1. Field1

2. Field2


and Fields of ContentType2 are

1. Field3

2 Field4


When these fields display on new form the order of fields is

1. Field1

2. Field2

3. Field3

4. Field4


But I need to change the order of field by

1. Field1

2. Field3

3. Field2

4. Field4


Can anyone help me to change the display order of fields in new and edit form?


Thanks & Regards,



Using List templates - saved template has no site definition id or feature id - does not appear in S

I have a Record Centre site in SharePoint Server 2010 and have created a number of record libraries. Due to a reorganisation, I need to split my main record library up into about 20 separate libraries, so decided to use the list template as a means to create the new libraries with the same content types, views and workflows.

Used one of my libraries with no content and did Library Settings - Save document library as template and gave a name. Seemed to save OK to the List template gallery.

When I go to Site Actions - More Options the new template does not appear

Have done a fair bit of searching and I think the problem is that the .stp does not seem to have any site definition id and no means to add one.

Have enabled the SharePoint Server Publishing feature at the site level, as suggested by another post, but still has not resolved the problem.

Would value any ideas or insight. Thanks

ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend