Question
I have a formatted search that lists a bunch of topics. I want to be able display the number of topics that are listed.
Thanks for any help.
Ryan
Environment
--
RyanBauerle - 05 Oct 2007
Answer
If you answer a question - or someone answered one of your questions - please remember to edit the page and set the status to answered. The status selector is below the edit box.
By default, a SEARCH shows the number of hits. If you want a custom format you can use a
SpreadSheetPlugin trick.
%SEARCH{ ..... format="$percntCALC{$SETM(num, +1)}$percnt other format..." }%
Total number of hits: %CALC{$GET(num)}%
--
PeterThoeny - 07 Oct 2007
Thanks! That did it.
--
RyanBauerle - 08 Oct 2007
It worked for me too, thanks.
I also had to put a
%CALC{$SET(num,0)}%
somewhere before the search in order to correctly handle empty result set.
--
Thomas Fozzi - 2013-04-15