All of my code here is written in email - so....

modifying your code:

$ListBoxName:="CCTransactionsLB"
COPY NAMED SELECTION([CC_Transactions];"TempCurrentSet")
LISTBOX GET TABLE SOURCE(*;$ListBoxName;$tableNum;$namedSelection;$highlightSet)
copy set($Highlightset;"$TempSet")   \\copy the highlight set, as you will need 
to rebuild it
USE SET($highlightSet)

//Do stuff with the records

USE NAMED SELECTION("TempCurrentSet”) //get the selection back
CLEAR NAMED SELECTION("TempCurrentSet”)

          \\ new code below -- loop over records, adding the desired ones to 
the highlight set
create empty set([table];$Highlightset)  \\clear the selection set
first record([table])

if ($Loop_Counter;1;records in selection([table]))
  if (is in set("$TempSet"))
    listbox select row(listbox;$loop_Counter;add to selection)
  end if
  next record([table])
end if

------------
Hell is other people 
     Jean-Paul Sartre
**********************************************************************
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:[email protected]
**********************************************************************

Reply via email to