Crosstab

K

Kou Vang

Currently I have a button on a formA that opens formB. FormB is based on a
crosstab query that I want to use a field in formA to query upon. I have
tried this several times and get the error of the Microsoft Jet engine not
recognizing the field on formA. The help states that this must be an error
in the parameter not being set. In order to use criteria in a crosstab, must
a parameter be set? How is it that I can type a known value into the
criteria of the crosstab query and it works, yet I cannot set the criteria of
the crosstab query to be based on a field in form? Should I just convert the
crosstab query to a table and use the table? Thanks.
 
K

KARL DEWEY

A couple of questions -
Does the formA field have information when the button is pushed?

How do you refere to the formA field?
Like this ---
[Forms]![FormAname]![FieldName]

Does the crosstab SQL statement include the parameter like this --
PARAMETERS [Forms]![FormAname]![FieldName] Text ( 255 );
TRANSFORM xxx xxx xxx
 
K

Kou Vang

I do refer the textbox like I normally would in the form of :

[forms]![formA][txtbox1]

As far as the parameter, I did not set one up, simply for the fact that it
makes no sense if the information is already on formA. If I want a
parameter, then I should just copy the query into a table, and just reference
the table to the formB instead. I guess I just don't understand why a
crosstab query is so different than any other query? I use the same syntax
for action queries, so I was just surprised to see it fail on my first
attempt when using a crosstab.

Kou

KARL DEWEY said:
A couple of questions -
Does the formA field have information when the button is pushed?

How do you refere to the formA field?
Like this ---
[Forms]![FormAname]![FieldName]

Does the crosstab SQL statement include the parameter like this --
PARAMETERS [Forms]![FormAname]![FieldName] Text ( 255 );
TRANSFORM xxx xxx xxx
--
KARL DEWEY
Build a little - Test a little


Kou Vang said:
Currently I have a button on a formA that opens formB. FormB is based on a
crosstab query that I want to use a field in formA to query upon. I have
tried this several times and get the error of the Microsoft Jet engine not
recognizing the field on formA. The help states that this must be an error
in the parameter not being set. In order to use criteria in a crosstab, must
a parameter be set? How is it that I can type a known value into the
criteria of the crosstab query and it works, yet I cannot set the criteria of
the crosstab query to be based on a field in form? Should I just convert the
crosstab query to a table and use the table? Thanks.
 
K

KARL DEWEY

You have to go the extra step in a crosstab query.
--
KARL DEWEY
Build a little - Test a little


Kou Vang said:
I do refer the textbox like I normally would in the form of :

[forms]![formA][txtbox1]

As far as the parameter, I did not set one up, simply for the fact that it
makes no sense if the information is already on formA. If I want a
parameter, then I should just copy the query into a table, and just reference
the table to the formB instead. I guess I just don't understand why a
crosstab query is so different than any other query? I use the same syntax
for action queries, so I was just surprised to see it fail on my first
attempt when using a crosstab.

Kou

KARL DEWEY said:
A couple of questions -
Does the formA field have information when the button is pushed?

How do you refere to the formA field?
Like this ---
[Forms]![FormAname]![FieldName]

Does the crosstab SQL statement include the parameter like this --
PARAMETERS [Forms]![FormAname]![FieldName] Text ( 255 );
TRANSFORM xxx xxx xxx
--
KARL DEWEY
Build a little - Test a little


Kou Vang said:
Currently I have a button on a formA that opens formB. FormB is based on a
crosstab query that I want to use a field in formA to query upon. I have
tried this several times and get the error of the Microsoft Jet engine not
recognizing the field on formA. The help states that this must be an error
in the parameter not being set. In order to use criteria in a crosstab, must
a parameter be set? How is it that I can type a known value into the
criteria of the crosstab query and it works, yet I cannot set the criteria of
the crosstab query to be based on a field in form? Should I just convert the
crosstab query to a table and use the table? Thanks.
 

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