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 Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Soft search using Like or the equivalent 1

Status
Not open for further replies.

daybase

Technical User
Dec 13, 2002
115
GB
Help - I am having a mental block - I have an input form where I can define search criteria and all works fine but I want to make the search a little more flexible so that I can search for parts of names - equivalent to like "*" & [enter detail] & "*" in a query. Assistance please. Current code is

Dim stDocName As String
Dim stLinkCriteria As String

stDocName = "detaildata"

stLinkCriteria = "[nwthename]=" & "'" & Me![whichclient] & "'"

DoCmd.OpenForm stDocName, , , stLinkCriteria
 
How are ya daybase . . .

A starting point:
Code:
[blue]stLinkCriteria = "[nwthename]=" & "'[purple][b]*[/b][/purple]" & Me![whichclient] & "[purple][b]*[/b][/purple]'"[/blue]


Calvin.gif
See Ya! . . . . . .

Be sure to see thread181-473997
 
Many thanks - I had just had a lucid moment and got the answer myself but, as ever, thanks for the assistance.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top