SPList.GetDefaultViewForContentType method
Returns the default view of list data that is used by the specified content type.
Namespace: Microsoft.SharePoint
Assembly: Microsoft.SharePoint (in Microsoft.SharePoint.dll)
Syntax
'Declaration
Public Function GetDefaultViewForContentType ( _
id As SPContentTypeId _
) As SPView
'Usage
Dim instance As SPList
Dim id As SPContentTypeId
Dim returnValue As SPView
returnValue = instance.GetDefaultViewForContentType(id)
public SPView GetDefaultViewForContentType(
SPContentTypeId id
)
Parameters
id
Type: Microsoft.SharePoint.SPContentTypeIdThe content type identifier (ID).
Return value
Type: Microsoft.SharePoint.SPView
The view.
Remarks
This method gets the default view from the Views property.