Hi there,
i have a simple select query in which i need to pass in a value from a textfield on an access form. the query will populate a combobox.
how can i pass in a parameter to the query using the row source option in the designer
Printable View
Hi there,
i have a simple select query in which i need to pass in a value from a textfield on an access form. the query will populate a combobox.
how can i pass in a parameter to the query using the row source option in the designer
Not sure what you mean.
You could write your query in code:
"SELECT * FROM Foo WHERE foobar = '" & text1.text & "'"
or if it's an existing query, you could use the Parameters collection of, I think, the QueryDef object. Something like that, anyway, don't use it myself.
SELECT tbl_Category.Category
FROM tbl_Category
WHERE (((tbl_Category.Location)=Forms!Maintenance!cmboNewLocation));
add the control item you want the value from in the sql view of the query designer