var component = getComponent("dvwContent");
return component.getRowCount() + " documents have been found";
If I'm placing this code into a computed value outside of a filtered dynamic view (referred to by "dvwContent"), it should return me the number of entries found, referring to this question & answer: Count entries in XPages view
If the number of hits exceeds the page display limit, it is giving me the number of filled rows on the page + 2. So if I display 25 lines per page, it tells me that "27 documents have been found" (if I display 50 docs, it tells me 52) - even if there are a lot more pages. It works correctly if there are less hits than the page display limit.
Does anybody have a solution for displaying/counting the correct number of hits?