Compartilhar via


ViewCollection.GetByTitle Method

Returns the list view with the specified title.

Namespace:  Microsoft.SharePoint.Client
Assemblies:   Microsoft.SharePoint.Client.Silverlight (in Microsoft.SharePoint.Client.Silverlight.dll);  Microsoft.SharePoint.Client (in Microsoft.SharePoint.Client.dll)

Syntax

'Declaration
<RemoteAttribute> _
Public Function GetByTitle ( _
    strTitle As String _
) As View
'Usage
Dim instance As ViewCollection
Dim strTitle As String
Dim returnValue As View

returnValue = instance.GetByTitle(strTitle)
[RemoteAttribute]
public View GetByTitle(
    string strTitle
)

Parameters

Return Value

Type: Microsoft.SharePoint.Client.View
Returns a View instance representing the list view with the specified title.

Exceptions

Exception Condition
[System.ArgumentException]

No views in the view collection with the specified title. Error code: -2147024809.

[System.UnauthorizedAccessException]

The current user has insufficient permissions. Error code: -2147024891.

Remarks

If there is more than one list view with the specified title, the server must return one list view. It must not be a null reference (Nothing in Visual Basic).

See Also

Reference

ViewCollection Class

ViewCollection Members

Microsoft.SharePoint.Client Namespace