SPList.SaveAsNewView - Méthode
First tries to find if the view already exists. Overwrite it if yes, add a new view if no. Then extract all the adhoc filter/sort info from the URL and build and update the view's xml Returns the url of the new/overwritten view.
Espace de noms : Microsoft.SharePoint
Assembly : Microsoft.SharePoint (dans Microsoft.SharePoint.dll)
Syntaxe
'Déclaration
Public Function SaveAsNewView ( _
oldName As String, _
newName As String, _
privateView As Boolean, _
uri As Uri _
) As String
'Utilisation
Dim instance As SPList
Dim oldName As String
Dim newName As String
Dim privateView As Boolean
Dim uri As Uri
Dim returnValue As String
returnValue = instance.SaveAsNewView(oldName, _
newName, privateView, uri)
public string SaveAsNewView(
string oldName,
string newName,
bool privateView,
Uri uri
)
Paramètres
oldName
Type : System.StringThe name of the view the user did the adhoc filter on (is currently on).
newName
Type : System.StringThe desired name the user typed
privateView
Type : System.BooleanBoolean true when the user wants make a new view that's personal
uri
Type : System.UriUrl that keeps all the adhoc filter/sort inforatmion
Valeur renvoyée
Type : System.String
The url of the new/overwritten view