sharepoint - Custom list definition + custom content type = showing only one form field? -


is trying to use the custom fields, content types and features to deploy the list. So far, I have a custom type that refers to custom and Biltine fields. Content type inherited object (0x01).

Now, I create a custom list definition that refers to the content type and fields (Biltin and custom ones); I clearly see the ShowInDisplayForm, ShowInEditForm, ShowInEditForm values But when I design the feature and make a list based on the definition, I get a single title field in all forms!

However, if I add the field to the list from the UI, then it appears in the form! In addition, if I create a custom list from the UI and add content types, then these fields are shown in the form!

What's going on with this?

Anyway, I use the VSSESS tool for Visual Studio, before it prepares a lot for content correctly.

Some code:

  & lt; Content Type & gt; & Lt; ContentTypeRef id = "0x01003420C661289843dbAB9E41F43C23BFD0" /> & Lt; / CONTENTTYPES & gt; & Lt; Fields & gt; & Lt; Field ID = "{fa564e0f-0c70-4ab9-b863-0177e6ddd247}" name = "title" group = "$ Resources: core, Extended_Columns" required = "true" ShowInDisplayForm = "true" ShowInEditForm = "true" ShowInNewForm = "TRUE "Type =" text "sortable =" TRUE "filterable =" TRUE "SourceID =" http://schemas.microsoft.com/sharepoint/v3 "/> & Lt; Field ID = "{B4629012-C672-4911-B0D0-B9CB2DA44ED2}" DisplayName = "Jautājumu pacēla" group = "$ Resources: core, Extended_Columns" name = "QuestionRisedBy" required = "true" ShowInDisplayForm = "true" ShowInEditForm = " Correct "ShowInNewForm =" TRUE "type =" user "ordered =" TRUE "filterable =" TRUE "SourceID =" http://schemas.microsoft.com/sharepoint/v3 "/> & Lt; Field ID = "{6DF9BD52-550E-4a30-BC31-A4366832A87F}" DisplayName = "Komentārs" group = "$ Resources: core, Extended_Columns" name = "note" AppendOnly = "true" required = "false" NumLines = "12 "Type =" Note "ShowInstreamForm =" True "ShowEditify =" Right "ShowNew Form =" Right "Sortable =" False "Filters =" False "SourceID =" http://schemas.microsoft.com/sharepoint/v3 "/> & Lt; Field ID = "{FC072586-E8BB-444f-AAA4-8D5745FBC096}" DisplayName = "ParentItemId" group = "$ Resources: core, able to sort Extended_Columns" name = "AgendaParentItemId" required = "true" type = "Integer" = "Incorrect" filterable = "incorrect" SourceID = "http://schemas.microsoft.com/sharepoint/v3" /> & Lt; Field ID = "{29207E42-E107-4379-B620-BAAFC461276B}" DisplayName = "AgendaRootItemId" group = "$ Resources: core, able to sort Extended_Columns" name = "AgendaRootItemId" required = "true" type = "Integer" = "Incorrect" filterable = "incorrect" SourceID = "http://schemas.microsoft.com/sharepoint/v3" /> & Lt; Field ID = "{06063FDB-3C2A-4141-91F7-28C2739CE6B5}" DisplayName = "AgendaItemClosed" group = "$ Resources: core, able to sort Extended_Columns" name = "AgendaItemClosed" required = "false" type = "boolean" = "TRUE" filterable = "TRUE" SourceID = "http://schemas.microsoft.com/sharepoint/v3" /> & Lt; / Fields & gt;  

Yes, the field type is fieldr for all the fields (well, they are inherited Not found). Although I have read that while defining contet types in schema.xml, (this is strange), if you add content content programmatically, then it adds CTYPE field to correctly define .

By the way, the Microsoft extension is generated for the VSeWSS (VS) tool you are watching (all the references).

:

What do you need to do to have the same elements as the content type element with the same ID? It's a little weird, but in reality you need to define fields twice, in content type and in schema.xml to do this work. You can leave the group and some other properties.

However, if I do not use the field, I will get an exception:

  [COMException (0x80004005): Nevar Pabigt Sato Dabby. Lūdzu, mēģiniet vēlreiz] Microsoft.SharePoint.Library.SPRequestInternalClass.GetViewsSchemaXml (string bstrUrl, string bstrListName, Boolean bFullBlown, ISP2DSafeArrayWriter p2DWriter, Int32 & amp; plDefaultViewIndex) +0 Microsoft.SharePoint.Library.SPRequest.GetViewsSchemaXml (string bstrUrl, string bstrListName Oh, well, anyway, I've read an article anywhere (now can not find the article) that suggests adding the content type. Feature receiver, then it can be properly shown fields in the form . 


Comments

Popular posts from this blog

c# - ListView onScroll event -

PHP - get image from byte array -

Linux Terminal Problem with Non-Canonical Terminal I/O app -