SPListItem.Folder Property

Gets a folder object that is associated with a folder item.

Namespace:  Microsoft.SharePoint
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)
Available in Sandboxed Solutions: Yes
Available in SharePoint Online

Syntax

'Declaration
Public ReadOnly Property Folder As SPFolder
    Get
'Usage
Dim instance As SPListItem
Dim value As SPFolder

value = instance.Folder
public SPFolder Folder { get; }

Property Value

Type: Microsoft.SharePoint.SPFolder
An SPFolder object that represents the folder if the item is a folder; otherwise a null reference (Nothing in Visual Basic).

See Also

Reference

SPListItem Class

SPListItem Members

Microsoft.SharePoint Namespace