• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 166
  • Last Modified:

How to find the occurance of a string in a string

What code will find the string "bozo" in the string "the name of the clown is bozo the clown.
??
0
rbend
Asked:
rbend
  • 6
  • 2
1 Solution
 
kamallCommented:
SearchString="the name of the clown is bozo the clown"
MyPos = Instr(4, SearchString, "bozo")
0
 
kamallCommented:
MyPos will return the positin in the SearchString at which 'bozo' is found. If it is not found, a 0 will be returned.
0
 
kamallCommented:
In the given example, it will return 26.
0
The new generation of project management tools

With monday.com’s project management tool, you can see what everyone on your team is working in a single glance. Its intuitive dashboards are customizable, so you can create systems that work for you.

 
kamallCommented:
Did you try it?
0
 
rbendAuthor Commented:
Kamall: here's your points.
You wouldn't know how to "kill" an app if I know the contents of the Title Bar of it's window would you?
0
 
kamallCommented:
rbend,
Thanks for the points.
Sometime ago I saw such a code snippest, but I really don't have such code in my knowledge base.
I will try to search for it, and will inform you if I find something.
Best regards.
0
 
kamallCommented:
Well, I found some code on my system, but it is a 16-bit code.
If you know how to modify it to a 32-bit, I can e-mail it to you.
0
 
rbendAuthor Commented:
No thanks kamall..I got that code elsewhere.
0

Featured Post

Hire Technology Freelancers with Gigs

Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.

  • 6
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now