Skip to Content

FormulaField.usecount not correct inside subreport

Feb 02, 2017 at 02:54 PM


avatar image
Former Member

Hi, I'm using a code to remove all not used FormulaField in a report. The code i like:

For Each myformulaField As FormulaField In eport.DataDefController.DataDefinition.FormulaFields)

If myformulaField.UseCount = 0 Then I



This code work correct for FormulaField in a report but don't work in subreport. The usecount value is always 0 for Formulafields in subreport.

Have any idea ?


10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

1 Answer

Best Answer
Don Williams
Mar 21, 2017 at 05:52 PM

Hi Filippo,

You don't have any code to open the subreport and get it's formula fields

See this sample I wrote, in the drop down list box on the right side select formula fields, it scans for subreports and show them also.


10 |10000 characters needed characters left characters exceeded