A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Using Forms
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Expression in Query Criteria



 
 
Thread Tools Display Modes
  #21  
Old September 1st, 2005, 09:02 PM
Klatuu
external usenet poster
 
Posts: n/a
Default

Okay, but I wont be able to get to it until tomorrow, I am in the middle of
hot project at the moment.



"jwinder" wrote:

anyway I can send them to you?

"Klatuu" wrote:

Without the objects in front of me, I can't tell. I know the examples I sent
work, because I use both versions.

"ryan_eng" wrote:

I have a similar problem to jwinder.
I have a subform with 3 combo boxes that have to be all related. The first
one is Task_ID, a combo box that grabs a list from another table. The second
is Act_Type, which is just a list I enterred manually. The third is Act_ID,
which is based on a query and needs to be filtered using the values of the
previous two combo boxes. I tried using the expression Klatuu dug up but its
not working. I still get the "enter parameter value" dialog box with the
expression shown.

I really need this to work, pleeeeeease help me.

RYAN


"Klatuu" wrote:

Okay, I had to go back and dig out an app I did 6 yrs ago and found the right
syntax. Mine is this:
Like [Forms]![frmClientSearch]![txtLastName] & "*"

So your's should be like this:
Like [Forms]![Query - Catalog Append Table]![Basic_Category] & "*"
"jwinder" wrote:

nope...doesn't work that way either.

"Klatuu" wrote:

Should be the name of the combo box. I wonder if because you are using LIKE,
it should be :

Like "'" & [Forms]![Query - Catalog Append Table]![Basic_Category] & "'"

"jwinder" wrote:

nope..still did not work. I now have
Like [Forms]![Query - Catalog Append Table]![Basic_Category]

Should the [Basic_Category] be the field name of the table or the name of
the Combo Box? As it is, it is the name of the Combo Box.

"Klatuu" wrote:

hmmmm, I thought I had copied from your post. You only need it one time:
Like [forms]![MyFormName]![Basic_Category]
"jwinder" wrote:

yes...one column. I was just doing what I thought you asked me to do...

you wrote: Like [forms]![MyFormName]![Basic_Category] & [Forms]![Query -
Catalog Append Table]![BasicCategory] & [forms]![MyFormName]![Basic_Category]


"Klatuu" wrote:

Now you are up to 3 times. Is this all in the criteria for one column in the
query? It doesn't seem to make any sense.

"jwinder" wrote:

seems llike I have something in there too many times... I now have the
following:
Like [forms]![Query - Catalog Append Table]![Basic_Category] &
[Forms]![Query - Catalog Append
Table]![BasicCategory] & [forms]![Query - Catalog Append
Table]![Basic_Category]

When I run the Query (with no criteria in any of the fields) i get a pop up
box with the title "enter Parameter Value" and below that
"Forms!Query-Catalog Append" then a blank List Box.


"Klatuu" wrote:

Like [Me].[Basic_Category] & [Forms]![Query - Catalog Append
Table]![BasicCategory] & [Me].[Basic_Category]
I'm curious as to why you have basiccategory in criteria twice. Try it like
this:
Like [forms]![MyFormName]![Basic_Category] & [Forms]![Query - Catalog Append
Table]![BasicCategory] & [forms]![MyFormName]![Basic_Category]

"jwinder" wrote:

nope..didn't work. :-(

this what I entered:
Like [Me].[Basic_Category] & [Forms]![Query - Catalog Append
Table]![BasicCategory] & [Me].[Basic_Category]
(When I saved it, it put in the extra Brackets around Me. and Basic_Category)

This is what I put into the other fields:
Like "*" & [Forms]![QueryFormName]![FieldName] & "*"

"Klatuu" wrote:

Refer to the value of the combo box in the query's criteria box

Me.MyCombo

"jwinder" wrote:

New Problem: Is there a way to have the expression in the Query Criteria box
search for values in a pull down list in a Combo Box on the query Form?
I.E. say there are four values in the combo box pull down list ( Cat, Dog,
Fish, Bird). If one of those values is selected (Dog) via the pull down list,
what does the expression have to look like to search for the selected value
(Dog)?

  #22  
Old September 2nd, 2005, 01:49 PM
ryan_eng
external usenet poster
 
Posts: n/a
Default

Is there any way I can get you to look at it? I've tried to write the
expression all different ways and it still gives the popup parameter entry.
I'm assuming the problems lie in that the combo box is in a subform, but I'm
pretty sure I covered that with the syntax:
[Forms]![frm_Time_Tracking]![frm_Time_Tracking_Details]![Forms]![Time_Type]
correct me if I'm wrong.

Do I need to simply write the above in the criteria box or am I missing
something? Am I missing something with the After Update requery?

RYAN

"Klatuu" wrote:

Without the objects in front of me, I can't tell. I know the examples I sent
work, because I use both versions.

"ryan_eng" wrote:

I have a similar problem to jwinder.
I have a subform with 3 combo boxes that have to be all related. The first
one is Task_ID, a combo box that grabs a list from another table. The second
is Act_Type, which is just a list I enterred manually. The third is Act_ID,
which is based on a query and needs to be filtered using the values of the
previous two combo boxes. I tried using the expression Klatuu dug up but its
not working. I still get the "enter parameter value" dialog box with the
expression shown.

I really need this to work, pleeeeeease help me.

RYAN


"Klatuu" wrote:

Okay, I had to go back and dig out an app I did 6 yrs ago and found the right
syntax. Mine is this:
Like [Forms]![frmClientSearch]![txtLastName] & "*"

So your's should be like this:
Like [Forms]![Query - Catalog Append Table]![Basic_Category] & "*"
"jwinder" wrote:

nope...doesn't work that way either.

"Klatuu" wrote:

Should be the name of the combo box. I wonder if because you are using LIKE,
it should be :

Like "'" & [Forms]![Query - Catalog Append Table]![Basic_Category] & "'"

"jwinder" wrote:

nope..still did not work. I now have
Like [Forms]![Query - Catalog Append Table]![Basic_Category]

Should the [Basic_Category] be the field name of the table or the name of
the Combo Box? As it is, it is the name of the Combo Box.

"Klatuu" wrote:

hmmmm, I thought I had copied from your post. You only need it one time:
Like [forms]![MyFormName]![Basic_Category]
"jwinder" wrote:

yes...one column. I was just doing what I thought you asked me to do...

you wrote: Like [forms]![MyFormName]![Basic_Category] & [Forms]![Query -
Catalog Append Table]![BasicCategory] & [forms]![MyFormName]![Basic_Category]


"Klatuu" wrote:

Now you are up to 3 times. Is this all in the criteria for one column in the
query? It doesn't seem to make any sense.

"jwinder" wrote:

seems llike I have something in there too many times... I now have the
following:
Like [forms]![Query - Catalog Append Table]![Basic_Category] &
[Forms]![Query - Catalog Append
Table]![BasicCategory] & [forms]![Query - Catalog Append
Table]![Basic_Category]

When I run the Query (with no criteria in any of the fields) i get a pop up
box with the title "enter Parameter Value" and below that
"Forms!Query-Catalog Append" then a blank List Box.


"Klatuu" wrote:

Like [Me].[Basic_Category] & [Forms]![Query - Catalog Append
Table]![BasicCategory] & [Me].[Basic_Category]
I'm curious as to why you have basiccategory in criteria twice. Try it like
this:
Like [forms]![MyFormName]![Basic_Category] & [Forms]![Query - Catalog Append
Table]![BasicCategory] & [forms]![MyFormName]![Basic_Category]

"jwinder" wrote:

nope..didn't work. :-(

this what I entered:
Like [Me].[Basic_Category] & [Forms]![Query - Catalog Append
Table]![BasicCategory] & [Me].[Basic_Category]
(When I saved it, it put in the extra Brackets around Me. and Basic_Category)

This is what I put into the other fields:
Like "*" & [Forms]![QueryFormName]![FieldName] & "*"

"Klatuu" wrote:

Refer to the value of the combo box in the query's criteria box

Me.MyCombo

"jwinder" wrote:

New Problem: Is there a way to have the expression in the Query Criteria box
search for values in a pull down list in a Combo Box on the query Form?
I.E. say there are four values in the combo box pull down list ( Cat, Dog,
Fish, Bird). If one of those values is selected (Dog) via the pull down list,
what does the expression have to look like to search for the selected value
(Dog)?

  #23  
Old September 2nd, 2005, 02:17 PM
Klatuu
external usenet poster
 
Posts: n/a
Default

Your syntax is still incorrect.
[Forms]![frm_Time_Tracking]![frm_Time_Tracking_Details]![Time_Type]
What you want is
[forms]![MainFormName]![SubFormName]![ControlName]

"ryan_eng" wrote:

Is there any way I can get you to look at it? I've tried to write the
expression all different ways and it still gives the popup parameter entry.
I'm assuming the problems lie in that the combo box is in a subform, but I'm
pretty sure I covered that with the syntax:
[Forms]![frm_Time_Tracking]![frm_Time_Tracking_Details]![Forms]![Time_Type]
correct me if I'm wrong.

Do I need to simply write the above in the criteria box or am I missing
something? Am I missing something with the After Update requery?

RYAN

"Klatuu" wrote:

Without the objects in front of me, I can't tell. I know the examples I sent
work, because I use both versions.

"ryan_eng" wrote:

I have a similar problem to jwinder.
I have a subform with 3 combo boxes that have to be all related. The first
one is Task_ID, a combo box that grabs a list from another table. The second
is Act_Type, which is just a list I enterred manually. The third is Act_ID,
which is based on a query and needs to be filtered using the values of the
previous two combo boxes. I tried using the expression Klatuu dug up but its
not working. I still get the "enter parameter value" dialog box with the
expression shown.

I really need this to work, pleeeeeease help me.

RYAN


"Klatuu" wrote:

Okay, I had to go back and dig out an app I did 6 yrs ago and found the right
syntax. Mine is this:
Like [Forms]![frmClientSearch]![txtLastName] & "*"

So your's should be like this:
Like [Forms]![Query - Catalog Append Table]![Basic_Category] & "*"
"jwinder" wrote:

nope...doesn't work that way either.

"Klatuu" wrote:

Should be the name of the combo box. I wonder if because you are using LIKE,
it should be :

Like "'" & [Forms]![Query - Catalog Append Table]![Basic_Category] & "'"

"jwinder" wrote:

nope..still did not work. I now have
Like [Forms]![Query - Catalog Append Table]![Basic_Category]

Should the [Basic_Category] be the field name of the table or the name of
the Combo Box? As it is, it is the name of the Combo Box.

"Klatuu" wrote:

hmmmm, I thought I had copied from your post. You only need it one time:
Like [forms]![MyFormName]![Basic_Category]
"jwinder" wrote:

yes...one column. I was just doing what I thought you asked me to do...

you wrote: Like [forms]![MyFormName]![Basic_Category] & [Forms]![Query -
Catalog Append Table]![BasicCategory] & [forms]![MyFormName]![Basic_Category]


"Klatuu" wrote:

Now you are up to 3 times. Is this all in the criteria for one column in the
query? It doesn't seem to make any sense.

"jwinder" wrote:

seems llike I have something in there too many times... I now have the
following:
Like [forms]![Query - Catalog Append Table]![Basic_Category] &
[Forms]![Query - Catalog Append
Table]![BasicCategory] & [forms]![Query - Catalog Append
Table]![Basic_Category]

When I run the Query (with no criteria in any of the fields) i get a pop up
box with the title "enter Parameter Value" and below that
"Forms!Query-Catalog Append" then a blank List Box.


"Klatuu" wrote:

Like [Me].[Basic_Category] & [Forms]![Query - Catalog Append
Table]![BasicCategory] & [Me].[Basic_Category]
I'm curious as to why you have basiccategory in criteria twice. Try it like
this:
Like [forms]![MyFormName]![Basic_Category] & [Forms]![Query - Catalog Append
Table]![BasicCategory] & [forms]![MyFormName]![Basic_Category]

"jwinder" wrote:

nope..didn't work. :-(

this what I entered:
Like [Me].[Basic_Category] & [Forms]![Query - Catalog Append
Table]![BasicCategory] & [Me].[Basic_Category]
(When I saved it, it put in the extra Brackets around Me. and Basic_Category)

This is what I put into the other fields:
Like "*" & [Forms]![QueryFormName]![FieldName] & "*"

"Klatuu" wrote:

Refer to the value of the combo box in the query's criteria box

Me.MyCombo

"jwinder" wrote:

New Problem: Is there a way to have the expression in the Query Criteria box
search for values in a pull down list in a Combo Box on the query Form?
I.E. say there are four values in the combo box pull down list ( Cat, Dog,
Fish, Bird). If one of those values is selected (Dog) via the pull down list,
what does the expression have to look like to search for the selected value
(Dog)?

  #24  
Old September 2nd, 2005, 02:25 PM
ryan_eng
external usenet poster
 
Posts: n/a
Default

ok, made that change but still getting the parameter entry pop-up. I made
sure that there is a requery in the After Update event for it. Anything else
I could be missing?

RYAN

"Klatuu" wrote:

Your syntax is still incorrect.
[Forms]![frm_Time_Tracking]![frm_Time_Tracking_Details]![Time_Type]
What you want is
[forms]![MainFormName]![SubFormName]![ControlName]

"ryan_eng" wrote:

Is there any way I can get you to look at it? I've tried to write the
expression all different ways and it still gives the popup parameter entry.
I'm assuming the problems lie in that the combo box is in a subform, but I'm
pretty sure I covered that with the syntax:
[Forms]![frm_Time_Tracking]![frm_Time_Tracking_Details]![Forms]![Time_Type]
correct me if I'm wrong.

Do I need to simply write the above in the criteria box or am I missing
something? Am I missing something with the After Update requery?

RYAN

"Klatuu" wrote:

Without the objects in front of me, I can't tell. I know the examples I sent
work, because I use both versions.

"ryan_eng" wrote:

I have a similar problem to jwinder.
I have a subform with 3 combo boxes that have to be all related. The first
one is Task_ID, a combo box that grabs a list from another table. The second
is Act_Type, which is just a list I enterred manually. The third is Act_ID,
which is based on a query and needs to be filtered using the values of the
previous two combo boxes. I tried using the expression Klatuu dug up but its
not working. I still get the "enter parameter value" dialog box with the
expression shown.

I really need this to work, pleeeeeease help me.

RYAN


"Klatuu" wrote:

Okay, I had to go back and dig out an app I did 6 yrs ago and found the right
syntax. Mine is this:
Like [Forms]![frmClientSearch]![txtLastName] & "*"

So your's should be like this:
Like [Forms]![Query - Catalog Append Table]![Basic_Category] & "*"
"jwinder" wrote:

nope...doesn't work that way either.

"Klatuu" wrote:

Should be the name of the combo box. I wonder if because you are using LIKE,
it should be :

Like "'" & [Forms]![Query - Catalog Append Table]![Basic_Category] & "'"

"jwinder" wrote:

nope..still did not work. I now have
Like [Forms]![Query - Catalog Append Table]![Basic_Category]

Should the [Basic_Category] be the field name of the table or the name of
the Combo Box? As it is, it is the name of the Combo Box.

"Klatuu" wrote:

hmmmm, I thought I had copied from your post. You only need it one time:
Like [forms]![MyFormName]![Basic_Category]
"jwinder" wrote:

yes...one column. I was just doing what I thought you asked me to do...

you wrote: Like [forms]![MyFormName]![Basic_Category] & [Forms]![Query -
Catalog Append Table]![BasicCategory] & [forms]![MyFormName]![Basic_Category]


"Klatuu" wrote:

Now you are up to 3 times. Is this all in the criteria for one column in the
query? It doesn't seem to make any sense.

"jwinder" wrote:

seems llike I have something in there too many times... I now have the
following:
Like [forms]![Query - Catalog Append Table]![Basic_Category] &
[Forms]![Query - Catalog Append
Table]![BasicCategory] & [forms]![Query - Catalog Append
Table]![Basic_Category]

When I run the Query (with no criteria in any of the fields) i get a pop up
box with the title "enter Parameter Value" and below that
"Forms!Query-Catalog Append" then a blank List Box.


"Klatuu" wrote:

Like [Me].[Basic_Category] & [Forms]![Query - Catalog Append
Table]![BasicCategory] & [Me].[Basic_Category]
I'm curious as to why you have basiccategory in criteria twice. Try it like
this:
Like [forms]![MyFormName]![Basic_Category] & [Forms]![Query - Catalog Append
Table]![BasicCategory] & [forms]![MyFormName]![Basic_Category]

"jwinder" wrote:

nope..didn't work. :-(

this what I entered:
Like [Me].[Basic_Category] & [Forms]![Query - Catalog Append
Table]![BasicCategory] & [Me].[Basic_Category]
(When I saved it, it put in the extra Brackets around Me. and Basic_Category)

This is what I put into the other fields:
Like "*" & [Forms]![QueryFormName]![FieldName] & "*"

"Klatuu" wrote:

Refer to the value of the combo box in the query's criteria box

Me.MyCombo

"jwinder" wrote:

New Problem: Is there a way to have the expression in the Query Criteria box
search for values in a pull down list in a Combo Box on the query Form?
I.E. say there are four values in the combo box pull down list ( Cat, Dog,
Fish, Bird). If one of those values is selected (Dog) via the pull down list,
what does the expression have to look like to search for the selected value
(Dog)?

  #25  
Old September 2nd, 2005, 02:28 PM
Klatuu
external usenet poster
 
Posts: n/a
Default

I really don't know. There is something wrong somewhere, because referencing
a form control in a query is a very common thing and should not be this
difficult.

"ryan_eng" wrote:

ok, made that change but still getting the parameter entry pop-up. I made
sure that there is a requery in the After Update event for it. Anything else
I could be missing?

RYAN

"Klatuu" wrote:

Your syntax is still incorrect.
[Forms]![frm_Time_Tracking]![frm_Time_Tracking_Details]![Time_Type]
What you want is
[forms]![MainFormName]![SubFormName]![ControlName]

"ryan_eng" wrote:

Is there any way I can get you to look at it? I've tried to write the
expression all different ways and it still gives the popup parameter entry.
I'm assuming the problems lie in that the combo box is in a subform, but I'm
pretty sure I covered that with the syntax:
[Forms]![frm_Time_Tracking]![frm_Time_Tracking_Details]![Forms]![Time_Type]
correct me if I'm wrong.

Do I need to simply write the above in the criteria box or am I missing
something? Am I missing something with the After Update requery?

RYAN

"Klatuu" wrote:

Without the objects in front of me, I can't tell. I know the examples I sent
work, because I use both versions.

"ryan_eng" wrote:

I have a similar problem to jwinder.
I have a subform with 3 combo boxes that have to be all related. The first
one is Task_ID, a combo box that grabs a list from another table. The second
is Act_Type, which is just a list I enterred manually. The third is Act_ID,
which is based on a query and needs to be filtered using the values of the
previous two combo boxes. I tried using the expression Klatuu dug up but its
not working. I still get the "enter parameter value" dialog box with the
expression shown.

I really need this to work, pleeeeeease help me.

RYAN


"Klatuu" wrote:

Okay, I had to go back and dig out an app I did 6 yrs ago and found the right
syntax. Mine is this:
Like [Forms]![frmClientSearch]![txtLastName] & "*"

So your's should be like this:
Like [Forms]![Query - Catalog Append Table]![Basic_Category] & "*"
"jwinder" wrote:

nope...doesn't work that way either.

"Klatuu" wrote:

Should be the name of the combo box. I wonder if because you are using LIKE,
it should be :

Like "'" & [Forms]![Query - Catalog Append Table]![Basic_Category] & "'"

"jwinder" wrote:

nope..still did not work. I now have
Like [Forms]![Query - Catalog Append Table]![Basic_Category]

Should the [Basic_Category] be the field name of the table or the name of
the Combo Box? As it is, it is the name of the Combo Box.

"Klatuu" wrote:

hmmmm, I thought I had copied from your post. You only need it one time:
Like [forms]![MyFormName]![Basic_Category]
"jwinder" wrote:

yes...one column. I was just doing what I thought you asked me to do...

you wrote: Like [forms]![MyFormName]![Basic_Category] & [Forms]![Query -
Catalog Append Table]![BasicCategory] & [forms]![MyFormName]![Basic_Category]


"Klatuu" wrote:

Now you are up to 3 times. Is this all in the criteria for one column in the
query? It doesn't seem to make any sense.

"jwinder" wrote:

seems llike I have something in there too many times... I now have the
following:
Like [forms]![Query - Catalog Append Table]![Basic_Category] &
[Forms]![Query - Catalog Append
Table]![BasicCategory] & [forms]![Query - Catalog Append
Table]![Basic_Category]

When I run the Query (with no criteria in any of the fields) i get a pop up
box with the title "enter Parameter Value" and below that
"Forms!Query-Catalog Append" then a blank List Box.


"Klatuu" wrote:

Like [Me].[Basic_Category] & [Forms]![Query - Catalog Append
Table]![BasicCategory] & [Me].[Basic_Category]
I'm curious as to why you have basiccategory in criteria twice. Try it like
this:
Like [forms]![MyFormName]![Basic_Category] & [Forms]![Query - Catalog Append
Table]![BasicCategory] & [forms]![MyFormName]![Basic_Category]

"jwinder" wrote:

nope..didn't work. :-(

this what I entered:
Like [Me].[Basic_Category] & [Forms]![Query - Catalog Append
Table]![BasicCategory] & [Me].[Basic_Category]
(When I saved it, it put in the extra Brackets around Me. and Basic_Category)

This is what I put into the other fields:
Like "*" & [Forms]![QueryFormName]![FieldName] & "*"

"Klatuu" wrote:

Refer to the value of the combo box in the query's criteria box

Me.MyCombo

"jwinder" wrote:

New Problem: Is there a way to have the expression in the Query Criteria box
search for values in a pull down list in a Combo Box on the query Form?
I.E. say there are four values in the combo box pull down list ( Cat, Dog,
Fish, Bird). If one of those values is selected (Dog) via the pull down list,
what does the expression have to look like to search for the selected value
(Dog)?

  #26  
Old September 2nd, 2005, 02:53 PM
ryan_eng
external usenet poster
 
Posts: n/a
Default

any chance you could have a look at it? I'm really at the end of my rope.

RYAN

"Klatuu" wrote:

I really don't know. There is something wrong somewhere, because referencing
a form control in a query is a very common thing and should not be this
difficult.

"ryan_eng" wrote:

ok, made that change but still getting the parameter entry pop-up. I made
sure that there is a requery in the After Update event for it. Anything else
I could be missing?

RYAN

"Klatuu" wrote:

Your syntax is still incorrect.
[Forms]![frm_Time_Tracking]![frm_Time_Tracking_Details]![Time_Type]
What you want is
[forms]![MainFormName]![SubFormName]![ControlName]

"ryan_eng" wrote:

Is there any way I can get you to look at it? I've tried to write the
expression all different ways and it still gives the popup parameter entry.
I'm assuming the problems lie in that the combo box is in a subform, but I'm
pretty sure I covered that with the syntax:
[Forms]![frm_Time_Tracking]![frm_Time_Tracking_Details]![Forms]![Time_Type]
correct me if I'm wrong.

Do I need to simply write the above in the criteria box or am I missing
something? Am I missing something with the After Update requery?

RYAN

"Klatuu" wrote:

Without the objects in front of me, I can't tell. I know the examples I sent
work, because I use both versions.

"ryan_eng" wrote:

I have a similar problem to jwinder.
I have a subform with 3 combo boxes that have to be all related. The first
one is Task_ID, a combo box that grabs a list from another table. The second
is Act_Type, which is just a list I enterred manually. The third is Act_ID,
which is based on a query and needs to be filtered using the values of the
previous two combo boxes. I tried using the expression Klatuu dug up but its
not working. I still get the "enter parameter value" dialog box with the
expression shown.

I really need this to work, pleeeeeease help me.

RYAN


"Klatuu" wrote:

Okay, I had to go back and dig out an app I did 6 yrs ago and found the right
syntax. Mine is this:
Like [Forms]![frmClientSearch]![txtLastName] & "*"

So your's should be like this:
Like [Forms]![Query - Catalog Append Table]![Basic_Category] & "*"
"jwinder" wrote:

nope...doesn't work that way either.

"Klatuu" wrote:

Should be the name of the combo box. I wonder if because you are using LIKE,
it should be :

Like "'" & [Forms]![Query - Catalog Append Table]![Basic_Category] & "'"

"jwinder" wrote:

nope..still did not work. I now have
Like [Forms]![Query - Catalog Append Table]![Basic_Category]

Should the [Basic_Category] be the field name of the table or the name of
the Combo Box? As it is, it is the name of the Combo Box.

"Klatuu" wrote:

hmmmm, I thought I had copied from your post. You only need it one time:
Like [forms]![MyFormName]![Basic_Category]
"jwinder" wrote:

yes...one column. I was just doing what I thought you asked me to do...

you wrote: Like [forms]![MyFormName]![Basic_Category] & [Forms]![Query -
Catalog Append Table]![BasicCategory] & [forms]![MyFormName]![Basic_Category]


"Klatuu" wrote:

Now you are up to 3 times. Is this all in the criteria for one column in the
query? It doesn't seem to make any sense.

"jwinder" wrote:

seems llike I have something in there too many times... I now have the
following:
Like [forms]![Query - Catalog Append Table]![Basic_Category] &
[Forms]![Query - Catalog Append
Table]![BasicCategory] & [forms]![Query - Catalog Append
Table]![Basic_Category]

When I run the Query (with no criteria in any of the fields) i get a pop up
box with the title "enter Parameter Value" and below that
"Forms!Query-Catalog Append" then a blank List Box.


"Klatuu" wrote:

Like [Me].[Basic_Category] & [Forms]![Query - Catalog Append
Table]![BasicCategory] & [Me].[Basic_Category]
I'm curious as to why you have basiccategory in criteria twice. Try it like
this:
Like [forms]![MyFormName]![Basic_Category] & [Forms]![Query - Catalog Append
Table]![BasicCategory] & [forms]![MyFormName]![Basic_Category]

"jwinder" wrote:

nope..didn't work. :-(

this what I entered:
Like [Me].[Basic_Category] & [Forms]![Query - Catalog Append
Table]![BasicCategory] & [Me].[Basic_Category]
(When I saved it, it put in the extra Brackets around Me. and Basic_Category)

This is what I put into the other fields:
Like "*" & [Forms]![QueryFormName]![FieldName] & "*"

"Klatuu" wrote:

Refer to the value of the combo box in the query's criteria box

Me.MyCombo

"jwinder" wrote:

New Problem: Is there a way to have the expression in the Query Criteria box
search for values in a pull down list in a Combo Box on the query Form?
I.E. say there are four values in the combo box pull down list ( Cat, Dog,
Fish, Bird). If one of those values is selected (Dog) via the pull down list,
what does the expression have to look like to search for the selected value
(Dog)?

 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
dlookup documentation? Fredrated New Users 1 May 19th, 2005 11:10 PM
Using textbox on form as query criteria Jess Running & Setting Up Queries 1 May 19th, 2005 08:30 PM
Access97 Query expression truncated by Access2000 Bilbo Running & Setting Up Queries 1 December 7th, 2004 12:15 AM
Print Taher Setting Up & Running Reports 1 August 31st, 2004 09:07 PM
Changing Query Selection criteria Ceci Running & Setting Up Queries 0 June 8th, 2004 07:17 AM


All times are GMT +1. The time now is 07:49 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.