>Thanks Cetin,
>
>I think I have it working now. I have selt the row source type to 3 - SQL Statement and then set the row source to:
>
>Select mainstnd.key2 from "U:\Data\Mainstnd.dbf"
>
>The values are now shown in the list which is great. But what it also does is open up a temp tables with the same values. How can I stop the showing of the temp table or cursor?
>
>Many Thanks
As an example doing that in code :
ie: Listbox.init
with this
.RowSourcetype = 3
.Rowsource = 'Select mainstnd.key2'+;
' from ("U:\Data\Mainstnd.dbf")'+;
' into cursor crsMyKeys'
.ColumnCount = 1
endwith
PS: With a rowsource like this if I were you I'd do :
Select mainstnd.key2 as ShowInLst, * ...
It'd make it possible to access any field value using crsMyKeys as an alias while only showing the first column in listbox.
Cetin