Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Selecting Multiple File
Message
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
00272857
Message ID:
00273387
Views:
18
>>>>I've been trying to write a form that will allow a user to select multiple datafiles and store them in an array. I'm using a listbox to display the selected files and I have an add button that uses getfile() and AINS to insert the selected file into the array. AINS is working, but after I refresh the control or the entire form, the listbox only displays the number of elements that the form started with. The array is updated and if I quit the form then come back all of the elements are there. Initially I had the numberofelements set to =alen(ArrayName), that did not work, so I tried hard coding it to 30 and that did not work. Any ideas?
>>>
>>>
>>>I think you are missing the requery method. After inserting into the array then call:
>>> ThisForm.lstMyListBox.Requery
>>>Then do the refresh. I missed that the first time I worked with the listbox too.
>>
>>Thanks! That worked!
>
>Hi Marvin,
>
>Just a suggestion. Rather than GETFILE(), I'd use the Common Dialogs ActiveX control's ShowOpen method. The flags property of this control will allow the user to select multiple files in the same directory with a single call.

Good idea? Which OCX is the ShowOpen method located in? I could not find it.

Thanks! Marvin
Marvin Masson
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform