Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Adding pictures in a listbox with a large array
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
Adding pictures in a listbox with a large array
Miscellaneous
Thread ID:
00368884
Message ID:
00368884
Views:
66
I have a multi-select listbox with a RowSource that is an array with two colums and about 500 rows. Its function is to display the text description of an item in column 1 and then store the contents of column two (a code) in a table field in the DE. Because it is multi-select and has to store several codes after user selection, it is not bound to anything but instead stores a concatenation of the selected codes (from column 2) in the underlying field.

It works great, with one problem: I want to put a small .BMP file (showing a checkmark) as the .Picture property for the saved code selections. IOW, I have written a method that scans the .List and, for each item in the list, checks the content of the underlying field for that code. This method is run by, for example, the form's Refresh() to update the checkmarks.

The problem is that there seems to be a limit to the number of rows in the array that will allow this latter "checking" method to work. If I use the full array (500 +/- items), the scan of the list seems to wipe out checkmarks after they are made. However, if I limit the array to about 1/10 of the full array, it works just fine, with no wipe out. (I have not tried to see how many rows I can add before it starts to fail again.)

Is there an upper limit to the size of a listbox array? I can't use a combobox, bec. I need the multi-select functionality.

Thanks for any thoughts.
Jim Wheelock
Next
Reply
Map
View

Click here to load this message in the networking platform