How can I generate a registration number in PloneFormGen?

Hi, in this posting, there is a solution:

"I am trying to set up a registration form for a conference using PloneFormGen, and I would like to use a TALES Expression to count the number of existing records, add "1", then display this on the "Thank You" page as the registrant's registration number. Is this possible?"

But the counter do not work. Has anyone another solution?
(I use Plone 4.3.3 / PloneFormGen 1.7.17)

For more complex use cases like this I tend to use Plomino. It gives you a proper query interface to do things like ensure an id is unique against your saved records.