Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Follow An Item
Message
 
To
15/05/2007 07:08:03
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Title:
Environment versions
Visual FoxPro:
VFP 6 SP5
OS:
Windows XP SP2
Network:
Windows 2000 Server
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01225454
Message ID:
01225865
Views:
21
Hi Fred,

>How do I ensure that the highlighted record becomes the newly append record ?

Make sure that the BoundColumn points to the primary key in the table. When you add a record, call the listbox's Requery method. Then set the value property to the primary key of the new record.

If you don't have a bound column, you need to scan through the list to find the record using the List array property. Then set ListIndex to the index of the new record.

> How can I make the highlight follow the edited record to its new position in the List Index?

Using the same method as above. The only difference is that you don't have to call Requery. You need to update the code on every place where you navigate in the list. The list is not connected with the table. Therefore navigation by default has no impact on the list box.
--
Christof
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform