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.6.492
Syntax
IAssetFolder ParentFolder()

Return Value

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