Partager via


UPDATEFIELD Method

Modifies the schema of an existing field in a SharePoint list.

Syntax

<Method ID="Text">
  <SetList Scope="Request">GUID</SetList>
  <SetVar Name="Cmd">UPDATEFIELD</SetVar>
  <SetVar Name="FieldXML">&lt;Field ColName=&quot;tp_Title&quot;
    Type=&quot;Text&quot; Name=&quot;Title&quot; DisplayName=&quot;Title&quot;
    FromBaseType=&quot;TRUE&quot; MaxLength=&quot;255&quot;
    Description=&quot;this is an update&quot;/&gt;
  </SetVar>
  <SetVar Name="owshiddenversion">Integer</SetVar>
</Method>

Parameters

ID = "Text"

Scope = "Request"

Name="Cmd"

Name = "FieldXML"

Name = "owshiddenversion"

Decoded

<Method ID="0,UPDATEFIELDTitle">
  <SetList Scope="Request">GUID</SetList>
  <SetVar Name="Cmd">UPDATEFIELD</SetVar>
  <SetVar Name="FieldXML">&lt;Field ColName=&quot;tp_Title&quot;
    Type=&quot;Text&quot; Name=&quot;Title&quot; DisplayName=&quot;Title&quot;
    FromBaseType=&quot;TRUE&quot; MaxLength=&quot;255&quot;
    Description=&quot;this is an update&quot;/&gt;
  </SetVar>
  <SetVar Name="owshiddenversion">13</SetVar>
</Method>

Return Value

Success

Returns the code attribute, which is a signed-decimal representation of an HRESULT.

Error

Returns an XML-encoded Unicode (UTF-8) text string. See Error Message Format for Windows SharePoint Services for more information.

Sample Output