I want to design a popupmenu And I use SQL to find the title I need but I need to convert the table to an array in order to use Title From Variable xxx
Always use Fetch First, Fetch Next when looping thru a table. Using the Fetch Rec No isn't recommended as that won't work if the record you try to fetch has been deleted.
Here is a function that does the trick:
This could of course be extended to add a group by and an order by to the table and column to only use each unique value once and have the values ordered
PS: This works properly for a Char column. You would have to format your result if the column is of any other type.
Something like this: