Hi all,
I am trying to parse an HTML page for links using the position command but there is a problem with case-sensitivity. Is there a way I could make Position case insensitive?
Regards,
Mark
Case Insensitve Searching with Position
Moderators: JRL, Dorian (MJT support)
Hi,
Use the VBScript UCASE function to convert both items to upper case and then compare.
//The following two lines enables VBScript in your code
VBSTART
VBEND
Let>var=Hello World
//The following line converts the value in the var variable to uppercase.
VBEval>ucase("%var%"),var
Now you can use Position against var to do a case insensitive comparison - just put the value you are searching for in upper case.
Use the VBScript UCASE function to convert both items to upper case and then compare.
//The following two lines enables VBScript in your code
VBSTART
VBEND
Let>var=Hello World
//The following line converts the value in the var variable to uppercase.
VBEval>ucase("%var%"),var
Now you can use Position against var to do a case insensitive comparison - just put the value you are searching for in upper case.
MJT Net Support
[email protected]
[email protected]
- tony_smith
- Pro Scripter
- Posts: 70
- Joined: Wed May 14, 2003 8:25 pm
- Location: Vancouver BC Canada
Case sensitive Position command
I ran into this issues before... My post Jan09/2004, because the case-sentisitivy is not documented in help command reference, it took some doing to find out.
Besides document this in the help, I would like to see an enhancement to change the command to include a case switch. Is this possible?
Besides document this in the help, I would like to see an enhancement to change the command to include a case switch. Is this possible?