Microsoft KB Archive/104258

{| = Sample Code for Creating Multiple-Selection GET List Box =
 * width="100%"|

ID: Q104258

2.00 2.50 2.50a | 2.50 2.50a 3.00

MS-DOS         | WINDOWS The information in this article applies to:
 * Microsoft Visual FoxPro for Windows, version 3.0
 * Microsoft FoxPro for MS-DOS, versions 2.0, 2.5, 2.5a
 * Microsoft FoxPro for Windows, versions 2.5, 2.5a

SUMMARY
FoxPro does not include a multiple-selection GET object that is activated with a READ command. However, you can create a multiple-selection list object by storing the information that is selected in the VALID clause for the list object, as explained below.

MORE INFORMATION
There are several different methods of creating a multiple-selection list object. The following example demonstrates how to make selections in an array. (In the example, the array is called "test".) The selections are marked by a check mark [CHR(251)], and then the selection is displayed when the Done button is chosen. The VALID routine for the push button sorts the array and stores the selected options in a variable. All options that were selected are stored in the "checked" variable.