none
Custom field type inherit and xml file. RRS feed

  • Question

  • Hello everyone,

    For example i have created a custom field which inherits from SPFieldMultiLineText.

    Now in the fldtypes_*.xml i have:

    <Field Name="ParentType">Text</Field>

    And it seems to work, but the question is, should this be Note or should i leave it as Text?


    Wednesday, July 6, 2011 7:15 PM

Answers

All replies

  • Sure Note
    Sorin Sandu
    • Marked as answer by mtrixfroml Wednesday, July 6, 2011 8:29 PM
    Wednesday, July 6, 2011 7:25 PM
  • And what happens if i leave it as Text? :)
    Wednesday, July 6, 2011 7:47 PM
  • Anyway, found out the answer, its when you exceed 255 characters, if it is not Note you will get an exception :)
    • Marked as answer by mtrixfroml Wednesday, July 6, 2011 8:29 PM
    Wednesday, July 6, 2011 8:29 PM
  • Hello.

    I would like to continue this topic because I've some problems with my field type based on SPFieldMultiLineText.

    I want to have the same options during adding my CustomMultiLineText to list when I have when I adding Multi lines text to list. What should I do to have those options? I tought that if I set this property <Field Name="AllowBaseTypeRendering">TRUE</Field> to true, then everything will be the same as parent type.

    My fldtypes_CustomMultiLineText.xml looks like:

    <?xml version="1.0" encoding="utf-8" ?>
    <FieldTypes>
      <FieldType>
        <Field Name="TypeName">RECCustomMultiLineText</Field>
        <Field Name="ParentType">Note</Field>
        <Field Name="TypeDisplayName">REC Custom Multi Line Text</Field>
        <Field Name="TypeShortDescription">Custom Multi Line Text</Field>
        <Field Name="UserCreatable">TRUE</Field>
    	<Field Name="AllowBaseTypeRendering">TRUE</Field>
        <Field Name="ShowOnListAuthoringPages">TRUE</Field>
        <Field Name="ShowOnDocumentLibraryAuthoringPages">TRUE</Field>
        <Field Name="ShowOnSurveyAuthoringPages">TRUE</Field>
        <Field Name="ShowOnColumnTemplateAuthoringPages">TRUE</Field>
        <Field Name="FieldTypeClass">'Full assambly name'
        </Field>
      </FieldType>
    </FieldTypes>




    • Edited by newtong Wednesday, March 14, 2012 11:22 AM
    Wednesday, March 14, 2012 11:21 AM