You changed the Association text box control (FilterAssociation) to a combo box (cboFilterAssociation)?
What is the Row Source for the combo box?
You changed the Association text box control (FilterAssociation) to a combo box (cboFilterAssociation)?
What is the Row Source for the combo box?
Hi ssanfu,
RowSource of cbo
SELECT HelperID, HelperValue FROM tblHelper WHERE HelperTypeID=18 ORDER BY HelperValue;
Sorry for delay, I got called to do a work aarend!
IN any event, I was testing this for a different form and it will have cbo's in them.
I did re attach a new copy of this db in last post #13...
ps...I really didnt beleive it would be this complicated to change but again, i was wrong....
Last edited by d9pierce1; 12-11-2021 at 09:52 PM.
TempTestNew.zip
Hi ssanfu,
I attached this db again with a combo in it. Is there anyway to get this to work with a combo?
I am not familiar with search stuff and have only used Allen Browns method in past. However
with that said, i love your method and the filter as you type is just fantastic. I have 7 forms that
will need filters and 3 out of the 7 will really need to have combo boxes rather then txt.
I have searched google to the end and have found examples of this method with txt but nothing
that shows me a combo example? I know i have tried every .Value, .Column, "", "'". '". and so on
with no results that were sucessful in coding this in the function....
I hate to bother you with this but i am at a loss here totally and would hate now to go back to
Allens methods. Be like starting all over again.
Thanks
Dave
Why are you not debugging this and also using Debug.Print to see what is being produced?
Why are you not using the same method as the other criteria?
Please use # icon on toolbar when posting code snippets.
Cross Posting: https://www.excelguru.ca/content.php?184
Debugging Access: https://www.youtube.com/results?sear...bug+access+vba
TempTest Newest.zip
Hi all,
I beleive I have done it. Not sure if absolutely correct method but it works now!
Thanks to all.
Dave
ps...Will mark solved!
I would put the call for any combo in the AfterUpdate event as well.?
Please use # icon on toolbar when posting code snippets.
Cross Posting: https://www.excelguru.ca/content.php?184
Debugging Access: https://www.youtube.com/results?sear...bug+access+vba
Welshgasman
Thanks, will do that!
Dave
Dave,
I added "_PK" and "_FK" suffixes to the PK and FK fields in the tables.
In "tblPerson" you have a field named "PersonTypeID_FK". I would have named it "HelperID_FK" because it is the link to "tblHelper.HelperID_PK".
BTW, RI cannot be enforced between "tblHelperType" and "tblHelper" because "tblHelper" is missing a record.
"tblHelperType.HelperTypeID_FK" (the many side) has a record with the value of 1, but there is not a corresponding record in the 1 side table.
Look at record 175 in ""tblHelper.HelperID_PK". The value in "tblHelper.HelperTypeID_FK" is 1.
You set row source for the combo box "cboFilterAssociation" to limit the selections two options: Family or Friend.
In "tblPerson", you are storing "tblHelper.HelperID_PK" in "tblPerson.PersonTypeID_FK.
I would set the row source of "cboFilterAssociation" to
Code:SELECT tblHelper.HelperID_PK, tblHelper.HelperValue FROM tblHelper ORDER BY tblHelper.HelperValue;
There were many changes that had to be made: the union query, the listbox record source, column count, column widths.
Then several places in the code. It took a while, but it is finally working (I think)......... (Try and not break it)![]()
Last edited by ssanfu; 12-13-2021 at 01:22 AM. Reason: fixed some things and added zip