Back to Devexpress

ICustomFunctionCategory Interface

corelibraries-devexpress-dot-dataaccess-dot-expressioneditor.md

latest2.5 KB
Original Source

ICustomFunctionCategory Interface

When implemented by a custom aggregate function, designates its functional category in the Expression Editor.

Namespace : DevExpress.DataAccess.ExpressionEditor

Assembly : DevExpress.DataAccess.v25.2.dll

NuGet Package : DevExpress.DataAccess

Declaration

csharp
public interface ICustomFunctionCategory
vb
Public Interface ICustomFunctionCategory

Remarks

Implement the ICustomFunctionCategory interface to define a category under which the Expression Editor should display the custom function. Otherwise, the custom function is displayed in the “String” function`s category.

Note

Reference the DevExpress.DataAccess package in your project to use ICustomFunctionCategory in the Pivot Grid control.

The following code snippet adds the custom StringConcat function in the “Aggregate” function`s category:

csharp
using DevExpress.DataAccess.ExpressionEditor;
// ...
namespace Dashboard_StringConcatAggregate {
    class StringConcatFunction : ICustomAggregateFunction, ICustomFunctionOperatorBrowsable, 
        ICustomFunctionCategory {
        // ...
        public string FunctionCategory => "Aggregate";
        // ...
    }
}
vb
Imports DevExpress.DataAccess.ExpressionEditor
' ...
Namespace Dashboard_StringConcatAggregate
    Friend Class StringConcatFunction
        Implements ICustomAggregateFunction, ICustomFunctionOperatorBrowsable, 
        ICustomFunctionCategory
        ' ...
        Private ReadOnly Property ICustomFunctionCategory_FunctionCategory As String Implements ICustomFunctionCategory.FunctionCategory
            Get
                Return "Aggregate"
            End Get
        End Property
        ' ...
    End Class
End Namespace

See Also

ICustomFunctionCategory Members

DevExpress.DataAccess.ExpressionEditor Namespace