Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Moving records between list boxes
Message
 
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00810627
Message ID:
00810650
Views:
7
Neil,

You may take a look at mover class in _movers class library in VFP FFC subdirectory.

>I have 2 list boxes on a form namely list 1 and list 2.
>
>I want to be able to move records from list 1 to list 2. I have successfully recreated this without having to use the mover class which I do not want to use.
>
>In the double click event of list 1 I have the following code:
>
>
>thisform.List2.AddItem(This.List(This.ListIndex))
>thisform.RemoveItem(This.ListIndex)
>
>
>In the double click event of list 2 I have the following code:
>
>
>thisform.list1.AddItem(This.List(This.ListIndex))
>thisform.RemoveItem(This.ListIndex)
>
>
>The problem I have is that when I double click records from list box 1 to list box 2 the records are copied over but still remain in list box 1. When I double click records in list box 2 to copy them over to list box 1 they DO remove from list box 2. I'm a bit confused!!
>
>Another piece of information is that List box 1 is populated from an on button click event on another form using an SQL statement. The form is released though once the user clicks this button.
>
>If somebody could help it would be greatly appreciated.
>
>Many THanks
--sb--
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform