Hi All,
I have a form wtih a subform.
In the subform is a combobox where I can select the whole description.
Is it possible to seach for a part of the the description?
search for a part of a field in a combobox in a subform
-
- NewLounger
- Posts: 10
- Joined: 30 Jun 2015, 11:46
- Location: The Hague
search for a part of a field in a combobox in a subform
You do not have the required permissions to view the files attached to this post.
Grtz, Ton
-
- Administrator
- Posts: 78585
- Joined: 16 Jan 2010, 00:14
- Status: Microsoft MVP
- Location: Wageningen, The Netherlands
Re: search for a part of a field in a combobox in a subform
Your code refers to a combo box named cboFilter but the form doesn't contain any combo box.
You also call a procedure named btnZoek, but there is no such procedure.
Did you strip down the database too far?
You also call a procedure named btnZoek, but there is no such procedure.
Did you strip down the database too far?
Best wishes,
Hans
Hans
-
- NewLounger
- Posts: 10
- Joined: 30 Jun 2015, 11:46
- Location: The Hague
Re: search for a part of a field in a combobox in a subform
My bad.
The cbofilter part was something I found on the net, but didn't use.
The cbofilter part was something I found on the net, but didn't use.
You do not have the required permissions to view the files attached to this post.
Grtz, Ton
-
- Administrator
- Posts: 78585
- Joined: 16 Jan 2010, 00:14
- Status: Microsoft MVP
- Location: Wageningen, The Netherlands
Re: search for a part of a field in a combobox in a subform
Your current code allows you to search for part of the description:
I guess I haven't understood your question. Could you try to explain it again?
I guess I haven't understood your question. Could you try to explain it again?
You do not have the required permissions to view the files attached to this post.
Best wishes,
Hans
Hans
-
- NewLounger
- Posts: 10
- Joined: 30 Jun 2015, 11:46
- Location: The Hague
Re: search for a part of a field in a combobox in a subform
When I want to add a new record, I can select the dropdown and start typing from the first character.
But I want to be able to look for any string anywhere in the field.
For example I need to add "schroeven" but I do not know the exact name. So I want to search for that anywhere in the field and select the field I need.
But I want to be able to look for any string anywhere in the field.
For example I need to add "schroeven" but I do not know the exact name. So I want to search for that anywhere in the field and select the field I need.
Grtz, Ton
-
- Administrator
- Posts: 78585
- Joined: 16 Jan 2010, 00:14
- Status: Microsoft MVP
- Location: Wageningen, The Netherlands
Re: search for a part of a field in a combobox in a subform
Which dropdown are you talking about?
Best wishes,
Hans
Hans
-
- NewLounger
- Posts: 10
- Joined: 30 Jun 2015, 11:46
- Location: The Hague
-
- Administrator
- Posts: 78585
- Joined: 16 Jan 2010, 00:14
- Status: Microsoft MVP
- Location: Wageningen, The Netherlands
Re: search for a part of a field in a combobox in a subform
I see now. Although it is possible in theory, it has nasty side effects in a continuous form. I'd leave it as it is.
Best wishes,
Hans
Hans
-
- Administrator
- Posts: 78585
- Joined: 16 Jan 2010, 00:14
- Status: Microsoft MVP
- Location: Wageningen, The Netherlands
Re: search for a part of a field in a combobox in a subform
If you'd like to try it, see the attached database. The combo box acts weirdly, in my opinion.
You do not have the required permissions to view the files attached to this post.
Best wishes,
Hans
Hans
-
- NewLounger
- Posts: 10
- Joined: 30 Jun 2015, 11:46
- Location: The Hague
Re: search for a part of a field in a combobox in a subform
Thanks for sharing, Hans.
It indeed acts weirdly, but it does do the job.
Grtz, Ton