General information
Category:
Forms & Form designer
>I have a list box that is an SQL statement and not tied to a particular controlsource. The REQUERY method apparently works only with a controlsource set. How do I have the listbox rerun the SQL when I change the param used in the SQL where clause?
I did this, I create a form, added a listbox and a command button. I made the RowSourceType SQL, and the RowSource this:
select to_name from orders where emp_id = pubvar into cursor a
Then, made the Click() of the button do Thisform.List1.Requery(). I defined pubvar as a number in the command window and ran the form.
As I changed teh value of pubvar and clicked my button, my list kept changing, and I didn't set a control source.
Anything else you can tell us that you did with teh form or list box? Whats the SQL?
Previous
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only