Filtering A Crosstab Query Dynamically

T

trekgoes2malaysia

Is there any way to filter a xtab query dynamically, that is, have it
filter based on a value or text string selected from a list box on a
form. I have tried parameters in the criteria row of the xtab query
as well as the following .....

[FORMS]![Form Name]![list box name]

but Access returns an error message saying it does not recognize the
criteria content as a valid field or expression.

Trek
 
R

Rob Parker

Have you defined the parameter in your query? For crosstab queries, you
MUST do this. You can use the reference to a control on a form as the
parameter; you need to declare the type. You can set the parameter(s) via
the Query - Parameters menu item, or enter it in the SQL view, eg:

PARAMETERS [FORMS]![Form Name]![list box name] Text;
TRANSFORM ...

HTH,

Rob
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top