Get current item POS

May 24, 2010 2 Replies

Hello All the gurus of RMS,



How can i get the item description of current selected item. I know that i can loop through the items like this and display the description: Dim i As Integer



For i = 1 To session.Transaction.Entries.count MsgBox(session.Transaction.Entries.Element(i).Description) Next



But it loops through all the items and messages all the item description ... I just want the last added item description to display..



Any help will be great!


How to select the current item programmaticaly: Save the key of the current TransactionEntry - IE: Transaction.CurrentEntryKey Use your loop to find the Transaction.Entry with that key

You might like to know that if you use the Add method with the key as the last parameter the new entry will be positioned after the current entry.

Hi,

If you want last item only try

MsgBox(session.Transaction.Entries.Element(session.Transaction.Entries.count).Description)

Regards, Arthur

Join the Discussion

Have something to add? Share your thoughts — no account required.

Didn't find your answer?

Ask the community — no account required