Peter, what exactly is in the Name property of the combo?
Is it:
product Label
i.e. with a space?
Or does it really have the underscore?
Or is product_Label the name of the label attached to the combo?
Dear Allen
I entered the following line into the Form property event, it looks
like
this:
=FindAsUTypeLoad ( [Form], "product_Label")
No chance, I always see the "product" in the combo box.
Do I have to change something else what I maybe forgot?
Thanks
Peter
:
In form design view, right-click the control you want to suppress, and
choose Properties. On the Other tab of the Properties box, is the Name
property. It is this name you need to use, not the Control Source
(which
is
what you see in the control on the form.)
Often the Name and Control Source are the same, and that's no problem.
But
if they are different, you must use the Name, not the Control Source
to
supress filtering of the control.
--
Allen Browne - Microsoft MVP. Perth, Western Australia.
Reply to group, rather than allenbrowne at mvps dot org.
I'm to nervous now to stop - so I tried it again.
*I entered the following into the On Load property: =FindAsUTypeLoad
(
[Form], "product") - product should be the contol name (if control
name
and
control source is the same) - It did not work, "product" is still in
the
combo box.
* than I tried it with this:=FindAsUTypeLoad ( [Form], "Product") -
Product
should be the field name (if field name and Caption is the same) -
it
didn't
work neither.
I believe if control source and control name are not the same than
please
tell me where to find the control name. If they are both the same
than
I
don't know what I could have done wrong.
Thanks
Peter
:
Re (b), you could put a button alongside the text box, and add the
code:
Me.txtFindAsUTypeValue = Null
Call FindAsUTypeChange(Me)
Re (a) you wanted to remove all the controls so they are not listed
in
the
combo? Did you use the name of the controls (not the name of the
fields)?
Post exactly what you used.
Hi Allen
thanks for your answer, it's working like you said in principle.
I do have two question concerning your "FindAsUType":
a) I wrote in the property (event) on my form as you instructed
for
filtering out each control name. I used quotes arround each
contol
and
commas
to seperate them. - Result: Not filtered, all controll names are
still
shown.
Any idea to help me?
b) if I write the search name in the text box it stays there
until I
delete
it with the mouse. Is there any possibility to clear the Textbox
with a
clear
button?
Thanks
Klaus
:
If the autonumber is tied to the family name, you could use a
combo
to
find
the record you want. There is a combo wizard to do that, or
follow
the
approach in this article:
Using a Combo Box to Find Records
at:
http://allenbrowne.com/ser-03.html
If you want to be able to search on any field, filtering the
form
with
each
keystroke, you could download the example in this article and
import
it
into
your database:
Find as you type - Filter forms with each keystroke
at:
http://allenbrowne.com/AppFindAsUType.html
Dear Sirs
I would like to create a "Search record" button in my form.
I did it with the wizzard but the it is only searching in
terms
of
"autonumber" (which is the primary key). I would like to
search
by
familyname.
How can I change that?