it is possible to add a character limit to the data displayed in a dx:PivotGridField Report in ASP.NET?

50 Views Asked by At

I have tried a custom template for the data cells of DevExpress.Web.ASPxPivotGrid.PivotGridField is CellTemplate for 20 character limit

<dx:PivotGridField FieldName="FieldName" Area="DataArea" Caption="Caption">
    <CellTemplate>
        <div style="white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100px;">
            <%# Eval("FieldName").ToString().Substring(0, Math.Min(Eval("FieldName").ToString().Length, 20)) %>
        </div>
    </CellTemplate>
</dx:PivotGridField>

and it shows Type 'DevExpress.Web.ASPxPivotGrid.PivotGridField' does not have a public property named 'CellTemplate'. so any correction or the alternative way I am looking for!

0

There are 0 best solutions below