Advertisement

05.27.2008 at 05:18AM PDT, ID: 23434487
[x]
Attachment Details

How to search exact word in a string?

Asked by avnish_tanna in Microsoft Visual Basic.Net, Miscellaneous Programming, C# Programming Language

I have a long description string. In which I need to find a particular whole word using VB.net.
Example:
If I search for the word "Spa" in the description field using indexOf, It returns the position where it finds word "Newspaper" or "Space" or "Spanish". I want to search only whole word "Spa".
Also, tried using regEx, but no luck.Start Free Trial
[+][-]05.27.2008 at 05:25AM PDT, ID: 21651201

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]05.27.2008 at 05:52AM PDT, ID: 21651396

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]05.27.2008 at 06:02AM PDT, ID: 21651464

Assisted solutions are selected by the member who asked the question as a comment that contributed to their question's solution.

Start your 7-day free trial to view this Assisted Solution or ask the Experts your question.

 
[+][-]05.27.2008 at 09:55AM PDT, ID: 21653500

View this solution now by starting your 7-day free trial. Setting up your free trial is quick, easy, and secure. We will return you to this solution, unlocked, when you're done.

 

About this solution

Zones: Microsoft Visual Basic.Net, Miscellaneous Programming, C# Programming Language
Sign Up Now!
Solution Provided By: ozo
Participating Experts: 3
Solution Grade: A
 
 
[+][-]05.28.2008 at 10:29PM PDT, ID: 21666557

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]05.28.2008 at 10:30PM PDT, ID: 21666558

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
 
Loading Advertisement...
20080716-EE-VQP-32 / EE_QW_2_20070628