I need to run a query depending on the value of a text box.
I am sorting on form called Sort
From a text box called Style
The field being sorted is called Type
My query, in field "type" has the criteria: [forms]![sort]![Style]
This works fine when the content of the textbox is for example "flat"
But is the contents of the textbox is "flat" Or "Terrace" then the query returns no reseults.
Im guessing that the problem is that when the textbox contains the Or command it is not running. If i just past "flat" Or "Terrace" into the query directly it runs fine so there is a problem with it accepting it from the text box
How can I resolve this? Many thanks Mark
I am sorting on form called Sort
From a text box called Style
The field being sorted is called Type
My query, in field "type" has the criteria: [forms]![sort]![Style]
This works fine when the content of the textbox is for example "flat"
But is the contents of the textbox is "flat" Or "Terrace" then the query returns no reseults.
Im guessing that the problem is that when the textbox contains the Or command it is not running. If i just past "flat" Or "Terrace" into the query directly it runs fine so there is a problem with it accepting it from the text box
How can I resolve this? Many thanks Mark