recordnumber in foundset

how can i get the recordnumber (1, 2, 3,…) in a list of the foundset easier as in a loop methode? i need this for example in an order-form with order-items.

thank you for help
thomas

Hi Thomas, can you be more specific?

Why doesn’t the foundset.getRecord(index) or controller.setSelectedIndex(index) work for you?

example:
i have an invoice with may be five related items (records in tabel positions) and i need the number of each related item. 1 for the first, 2 for the second and so on. i could not create this with a calculation.

regards
thomas

I THINK I understand now. I would, in such a case, create a sequence number upon adding an item to the invoice. In that case you have your number…

Does that help?

thank you… i will try this and post my result!

… but if you delete the 3rd item of five, you will have a sequence like 1, 2, 4, 5, or?

Hi Thomas,

Try adding a label to the item form and set the text to be ‘currentRecordIndex’ from the standard tags

This will show you the 1,2,3,4,5 visually and will also reorient itself if you delete item 3 to show only 1,2,3,4

Does this help or is there some other purpose that you need to numbers for

Cheers
Harry

the problem was, i don’t have ‘currentRecordIndex’ in my list of standard tags! but i added now a label and set the text in the property editor like %%currentRecordIndex%% and how wonder… it works!
thank you marcel, this is a big hint!

sorry… thank you harry!