Wild card entries in a text box

Ed3m

New Member
Joined
Mar 10, 2004
Messages
35
I have a form with a text box which allows the user to enter the name of customer and be given all their details in another form . When the name is entered the user runs a query which gives the results based on the value entered in the text box. However the text box only allows the user to enter the correct name or no records are shown. Is there a way to allow wildcard entries in the text box?
 

Some videos you may like

Excel Facts

When they said...
When they said you are going to "Excel at life", they meant you "will be doing Excel your whole life".

DaLiMan

Active Member
Joined
Jun 1, 2004
Messages
295
You mean like this?

Put this in your Query Criteria:
Code:
Like "*" & [What description?] & "*"
 

Ed3m

New Member
Joined
Mar 10, 2004
Messages
35

ADVERTISEMENT

I have a query running in the background
 

DaLiMan

Active Member
Joined
Jun 1, 2004
Messages
295
In my case I have a query which searches for a brand in a table in combination with customer data.

When you put the line:
Like "*" & [What description?] & "*"
in youre query and run it a msgbox will show up asking you :
What description?

Whatever you type in the Msgbox, it will search for it in the table with the * before and after it.

Now when you run a form which is based upon this query this MsgBox will ask you: What description? and the form wil show you all that is found according to your entry.

I hope this is what you are looking for.
Maybe bend it to youre needs a little.
 

Watch MrExcel Video

Forum statistics

Threads
1,122,521
Messages
5,596,645
Members
414,083
Latest member
Mrsash

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top