What I did for a mover container control was the following:
Set up two cursors, one for each listbox. Have a record_id field,
a display name field and an lShow field in each. Put _all_ available
records in _both_ cursors. To start, set lShow = .T. for all in the
left (source) listbox and lShow = .F. in the right (destination) one.
Filter both cursors on lShow.
Then if the user selects a record in the left box and goes Add, set
lShow = .F. for the source and .T. for the corresponding record in the
destination and refresh the lists. Voila, the record has moved.
I have noticed a problem with list boxes in general in VFP 5 -- there
must be a memory leak (not surprising given MS's history in this area)
because they often crash. I've had much better results in VFP 7 so
hopefully they've fixed the problem.
Hope this helps.
Bob
Précédent
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement