Share via


ViewCollection.GetByTitle method

Returns the list view with the specified title.

Namespace:  Microsoft.SharePoint.Client
Assembly:  Microsoft.SharePoint.Client (in Microsoft.SharePoint.Client.dll)

Syntax

'Declaration
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)
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