[]
        
(Showing Draft Content)

GrapeCity.ActiveReports.Rendering.CustomReportItemExtension.GetCustomPropertyAsEnum

GetCustomPropertyAsEnum Method

GetCustomPropertyAsEnum<T>(CustomReportItem, string, T)

Gets the custom property value as an enum.

Declaration
public static T GetCustomPropertyAsEnum<T>(this CustomReportItem reportItem, string propertyName, T defaultValue)
Parameters
Type Name Description
CustomReportItem reportItem

The custom report item.

string propertyName

The name of the custom property.

T defaultValue

The default value to return if the property does not exist or cannot be converted.

Returns
Type Description
T

The custom property value as an enum, or the default value if the property does not exist or cannot be converted.

Type Parameters
Name Description
T

The enum type.