Query to read listbox column

LB79

Registered User.
Local time
Today, 22:14
Joined
Oct 26, 2007
Messages
505
Hi,

I have a query that I want to read a column of data in a listbox. The bound column is already set for something else so I need to select the column to read. I have

Forms![frm_PMA_Export]![ATMT_lst1].[Column](4)

but I get the error Underfined Function in expression.
Is it not possible to do this?

Thanks
 
Hi Nathansav.
Thanks but the query won't know what me. is will it? I need to reference the form don't I?
 
You can but you have to do it this way:

Eval("[Forms]![frm_PMA_Export]![ATMT_lst1].[Column](4)")
 
You cannot use the column(x) in a query. But you can however make a hidden textbox on your form and set its controlsoure to:

=[ATMT_lst1].[Column](4)

and refrence this textbox in your query

JR
 
Fantastic! Thank you!
Eval("[Forms]![frm_PMA_Export]![ATMT_lst1].[Column](4)") worked a treat!

Not a fan of creating dummy text boxes but thanks for that suggestion
 

Users who are viewing this thread

Back
Top Bottom