Select records from a form using a Tick Box

thudson

Old Programmer
Local time
Today, 11:32
Joined
Apr 29, 2011
Messages
68
I have a form that when I select options in 2 unbound combo boxes and click a button that opens another form and is based on a query which checkes the selection in the 2 combo boxes. This is the criteria:
Like fCboSearch([Forms]![Frm_Verse_Cbo]![cbo_Evt]) and a similar one for the other combo box.
In the second form it listes the filtered data that meets the criteria.
On this form I have put a tick box which also has a field in the table where the data is extracted from.
If I ckeck a row on the form and run another query based on the previous query, with the tick box field criteria = True, I get no results. With the trick box set as false I get all of the rows that were filtered by the previous query.
Is there any way that I can code the form so that only the tick box I select is shown in the second query?
 
Is the query result from your combo boxes updateable ?
Is the tick box bound or unbound ?
 
Post your database with some sample data, (zip it) + a description how to reproduce the behaviour.
 
The run query button is not running the correct on the zip file I sent with my other post. I have re-zipped with the correct form run from the button and then I want to tick a radio button and generate a report from the selection made on the form, but this creates a form with all the greetings that are filtered by the previous filter. Ultimately I want to amalgamate the verse choice and the card parameters to print the verse in the correct place on the paper.
Thanks for your help!
 

Attachments

Minty
The combo box is filtered using a function:

Option Compare Database

Public Function fCboSearch(vCboSearch As Variant)

If IsNull(vCboSearch) Or vCboSearch = "" Then
fCboSearch = "*"
Else
fCboSearch = vCboSearch
End If
End Function

The tick box is bound to a field in the verses table. With it unbound it does not work!
 
try this i made some code on your report's Open event, just browse to it.
 

Attachments

Thanks arnelgp!
That works:)
Now I need to figure out how to set the report properties up so that the text prints out in the right place.
I have a table with the dimensions (in twips) and on the form is a combo box, which at present is unbound and has a list of the card sizes. What I want to do is use this list to filter the record that contains the dims for the card selected and then undate the report, which I understand must be done in design mode. Also there are some manual entries- I need to set the Top dim and also choose the Font and the Font size.
Am I asking the impossible?
 

Users who are viewing this thread

Back
Top Bottom