CAML cannot reference custom properties in custom fields

I am trying to create a custom field type in SharePoint. My custom field type has a custom property called CustomProperty.

<FieldTypes>
  <FieldType>
    <Field Name="TypeName">CustomField</Field>
    <Field Name="InternalType">CustomField</Field>
    ..............................
    ..............................
    <PropertySchema>
      <Fields>
        <Field Name="CustomProperty" DisplayName="CustomProperty" Type="Text" Hidden="TRUE" />
      </Fields>
      <RenderPattern Name="DisplayPattern">
      <Property Select="CustomProperty" />
    </RenderPattern>
  </FieldType>
</FieldTypes>

I am trying to display the value of this custom property in DisplayPattern.

But it seems that CAML cannot reference custom properties.

I do not get any value for the CustomValue property, even if it is set correctly.

Any idea how to reference custom properties in CAML?

+3
source share
2 answers

Unfortunately, there is no easy way to achieve this from what I saw.

- . GetCustomProperty ( "CustomProperty" ) GetFieldValue ( GetFieldValueAsHtml Note).

, GetFieldValue, CAML, .

+1

Source: https://habr.com/ru/post/1709190/


All Articles