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!

search space syntax

Status
Not open for further replies.

matrixindicator

IS-IT--Management
Sep 6, 2007
418
BE
Hoy,

I have an array which looks in a string a predefined textstring, a legal form like SL. This works fine, but when the legal form appears in the text he also takes it out.
"TRANSLUQUE 2000 SL" became "TRANUQUE 2000". So I try to say look only for the legal form where there is before first a space and then * or after a space and *
I tried
1. name_lf Like "* " & FJa(i))
2. name_lf Like FJa(i)) & " " & "*")
3. name_lf Like FJa(i)) & chr(32) & "*")
...

Code:
For i = LBound(FJa) To UBound(FJa)
 
If (name_lf Like "* " & FJa(i)) Or (name_lf Like "* " & FJa(i)) & " " & "*") Or (name_lf Like FJa(i) & " " & "*") Then ...
 
This may be over kill, but this sounds like a good place for regular expressions. I've used them successfully but am not an expert. Doing a search will turn up several post though.

this thread is a good one to thread222-1448141
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top