Johanna MB Help can explain Processing a MultiListBox control better than I:
Processing a MultiListBox control To read what items the user selected from a MultiListBox control, assign a handler procedure that is called when the user dismisses the dialog (for example, assign a handler to the OKButton control). Within the handler procedure, set up a loop to call ReadControlValue( ) repeatedly. The first call to ReadControlValue( ) returns the number of the first selected item; the second call to ReadControlValue( ) returns the number of the second selected item; etc. When ReadControlValue( ) returns zero, you have exhausted the list of selected items. If the first call to ReadControlValue( ) returns zero, there are no list items selected. -------------------------------- Not sure what you mean by a dataset, but, if a series of table s to be mapped, I assume your listbox items come from a 1-D array so you've already concatenated your path and table names into array strings, e.g. I = 1 Fetch first from MyTable Do while not EOT( MyTable) laMyPathArray( I) = MyTable.Path + "\" + MyTable.DataSet Fetch next from MyTable I = I + 1 Next In the above help text you have a loop in which you get each value from the list into a variable, say. E.g. lcNextTable = laMyPathArray( I) + ".TAB" With each you can issue: Open Table lcNextTable Interactive This the correct idea? HTH Terry McDonnell -----Original Message----- From: Johanna D. Tomesch [mailto:[EMAIL PROTECTED] Sent: 23 March 2005 15:00 To: Terry McDonnell Subject: MI-L MapBasic Question Hi all, I have a question regarding MapBasic and was hoping someone could point me in the right direction. I am writing a program that has a table containing the names and paths to multiple data sets. All the data set names populate a MultiListBox. When I select a data set out of the MultiListBox I want the program to read the path out of the table and then open the data set. I can't quite figure this out. Does anyone have any suggestions? Thanks a lot, Johanna D. Tomesch Research Associate Bureau of Water Supply Protection New York State Dept. of Health Ph: (518) 402-7728 Fax: (518) 402-7599 [EMAIL PROTECTED] --------------------------------------------------------------------- List hosting provided by Directions Magazine | www.directionsmag.com | To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Message number: 15778 --------------------------------------------------------------------- List hosting provided by Directions Magazine | www.directionsmag.com | To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Message number: 15780