Partager via


UpdateView Method

Modifies the specified view of a list.

Syntax

<Method ID="Text">
  <SetList Scope="Request">GUID</SetList>
  <SetVar Name="Cmd">NewView</SetVar>
  <SetVar Name="ViewType">HTML</SetVar>
  <SetVar Name="LocalizedTodayString">Text</SetVar>
  <SetVar Name="LocalizedMeString">Text</SetVar>
  <SetVar Name="ListVersion">0</SetVar>
  <SetVar Name="ViewFPModified">[TRUE|FALSE]</SetVar>
  <SetVar Name="ViewOrderk">k+1_Text</SetVar>
  <SetVar Name="ShouldDisplayTitle">[TRUE|FALSE]</SetVar>
  <SetVar Name="ShouldDisplayExpires">[TRUE|FALSE]</SetVar>
  <SetVar Name="SortFieldm">Text</SetVar>
  <SetVar Name="SortAscendingm">[TRUE|FALSE]</SetVar>
  <SetVar Name="IsThereAQuery">[TRUE|FALSE]</SetVar>
  <SetVar Name="FieldPickern">Text</SetVar>
  <SetVar Name="OperatorPickern">Eq</SetVar>
  <SetVar Name="CompareWithValuen"></SetVar>
  <SetVar Name="NextIsAndn">[TRUE|FALSE]</SetVar>
  <SetVar Name="GroupField1">Text</SetVar>
  <SetVar Name="GroupAscending1">[TRUE|FALSE]</SetVar>
  <SetVar Name="GroupField2">Text</SetVar>
  <SetVar Name="GroupAscending2">[TRUE|FALSE]</SetVar>
  <SetVar Name="CollapseGroups">[TRUE|FALSE]</SetVar>
  <SetVar Name="TotalText">COUNT</SetVar>
  <SetVar Name="ViewStyle">Integer</SetVar>
  <SetVar Name="RowLimit">Integer</SetVar>
  <SetVar Name="Paged">[TRUE|FALSE]</SetVar>
</Method>

Parameters

ID = "Text"

Scope = "Request"

Name = "Cmd"

ViewType = "Text"

LocalizedTodayString = "Text"

LocalizedMeString = "Text"

ListVersion = "Integer"

ViewFPModified = "[TRUE|FALSE]"

ViewOrdern = "n+1**_**Field"

ShouldDisplayField = "[TRUE|FALSE]"

SortFieldn = "tp_Field"

SortAscendingn = "[TRUE|FALSE]"

IsThereAQuery = "[TRUE|FALSE]"

FieldPickern = "Field"

OperatorPickern = "Text"

CompareWithValuen = "Value"

NextIsAndn = "[TRUE|FALSE]"

GroupField1 = "Text"

GroupAscending1 = "[TRUE|FALSE]"

GroupField2 = "Text"

GroupAscending2 = "[TRUE|FALSE]"

CollapseGroups = "[TRUE|FALSE]"

TotalField = "COUNT"

ViewStyle = "0"

RowLimit = "Integer"

Paged = "TRUE"

Decoded

<Method ID="UpdateView">
  <SetVar Name="Cmd">UpdateView</SetVar>
  <SetList Scope="Request">{bfce21b9-ffc9-4815-ad9c-3e92e06876bc}</SetList>
  <SetVar Name="View">{e5367bf3-43e9-45d6-bf9b-c2d120af9c86}</SetVar>
  <SetVar Name="ShouldDisplayID">TRUE</SetVar>
  <SetVar Name="ShouldDisplayTitle">TRUE</SetVar>
  <SetVar Name="ShouldDisplayExpires">TRUE</SetVar>
  <SetVar Name="ShouldDisplayLinkTitle">TRUE</SetVar>
  <SetVar Name="ShouldDisplayEditor">TRUE</SetVar>
  <SetVar Name="ViewOrder0">1_ID</SetVar>
  <SetVar Name="ViewOrder1">2_Title</SetVar>
  <SetVar Name="ViewOrder2">3_Expires</SetVar>
  <SetVar Name="ViewOrder3">4_LinkTitle</SetVar>
  <SetVar Name="ViewOrder4">5_Editor</SetVar>
  <SetVar Name="SortField1">tp_Title</SetVar>
  <SetVar Name="SortAscending1">FALSE</SetVar>
  <SetVar Name="IsThereAQuery">TRUE</SetVar>
  <SetVar Name="FieldPicker1">ID</SetVar>
  <SetVar Name="OperatorPicker1">Gt</SetVar>
  <SetVar Name="CompareWithValue1">4</SetVar>
  <SetVar Name="NextIsAnd1">FALSE</SetVar>
  <SetVar Name="FieldPicker2">ID</SetVar>
  <SetVar Name="OperatorPicker2">Lt</SetVar>
  <SetVar Name="CompareWithValue2">10</SetVar>
  <SetVar Name="NextIsAnd2">FALSE</SetVar>
  <SetVar Name="TotalID">COUNT</SetVar>
  <SetVar Name="ViewStyle">0</SetVar>
  <SetVar Name="RowLimit">100</SetVar>
  <SetVar Name="Paged">TRUE</SetVar>
</Method>

Return Value

Success

Returns the code attribute, which is a signed-decimal representation of an HRESULT, such as <Result ID="0,UpdateView" Code="0" />.

Error

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