Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Regular Expression- For a Numeric
#1
Not Solved
I have a situation to use regular expression.
The number is dynamic for example 445780.
I want use regular expression and make it fall between 2 numbers say for example (400000-500000).

How can i do that, please i need your help.
Thanks
Reply
#2
Not Solved
Code:
objRegExpr.Pattern = "[4][0-9]{5}|5000000"

Regards
Reply
#3
Not Solved
Thanks a lot kishore,
Hope you are helping a lot to guys like me who are beginners in QTP.

I could understand your answer, but the scenario is like this
I need to use the above code for
"Found 4643000 companies"
And this forms the check point in my script.
How can i use your code in the above scenario?

Thanks
Reply
#4
Not Solved
you can specify like
4\d\d\d\d\d/500000 which will always check for 400000 to 500000
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  trying to test that field doesn't have numeric characters jayraocourts 0 1,155 10-25-2019, 12:54 AM
Last Post: jayraocourts
  Need Any digit in xpath path using Regular expression Priyam 1 3,496 10-05-2016, 11:05 AM
Last Post: Ankur
  Regular expression to read two words in lowercase, uppercase and with and without spa sarahq49 1 3,361 04-09-2015, 01:56 AM
Last Post: sarahq49
  Regular expression and script optimisation Padmavathy 1 3,830 03-30-2015, 11:46 AM
Last Post: supputuri
  Regular expression in descriptive programming testernc 1 16,578 12-08-2014, 06:38 PM
Last Post: anshika.agarwal

Forum Jump:


Users browsing this thread: 2 Guest(s)