Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search Form help

Status
Not open for further replies.

dbar10

Programmer
Dec 5, 2008
196
US
I have a search feature on my clients form. One unbound box is used by the underlying query to find client by last Name. The expression used in the query is:

Like ("*" & [Forms]![Clients Add/Edit]![TextLname] & "*")

The problem is that if I type in the first 3 letters os a name, I get a return of all names with those letters in it as opposed to the names beginning with thos letters. Cna you help me right an expression that will acccomplish what I need? Thanks
 
Something like:
Code:
Like ([Forms]![Clients Add/Edit]![TextLname] & "*")
If you remove the wildcard from the front it will look for data starting with the specified value and a wildcard ending.

Hope this helps

HarleyQuinn
---------------------------------
The most overlooked advantage to owning a computer is that if they foul up there's no law against wacking them around a little. - Joe Martin

Get the most out of Tek-Tips, read FAQ222-2244 before posting.
 
Glad I could help [smile]

HarleyQuinn
---------------------------------
The most overlooked advantage to owning a computer is that if they foul up there's no law against wacking them around a little. - Joe Martin

Get the most out of Tek-Tips, read FAQ222-2244 before posting.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top