Click or drag to resize

IAssetItemParentFolder Method


Retrieves the parent asset folder of the context asset item.

Namespace:  Ingeniux.CMS
Assembly:  Ingeniux.CMS.CSAPI (in Ingeniux.CMS.CSAPI.dll) Version: 10.5.94
Syntax
IAssetFolder ParentFolder()

Return Value

Type: IAssetFolder
Parent asset folder of this context asset item. If the parent is the root of the Assets Tree, returns null.
Examples
Example of checking parent folder in OnBeforeDelete custom hook:
C#
if(contentItem.ParentFolder().Name == "views"){
    //Additional Actions
}
See Also