09-26-2012, 04:52 AM
In one of the fileds data needs to be between 10-99 and unique.
For now I am trying the following codes
Why does verification fail?
Any other idea for generating 2 digits unique number?
For now I am trying the following codes
Code:
Dim upperbound, lowerbound
upperbound=99
lowerbound =10
For i=10 to 99
CatEventCode=Int((upperbound - lowerbound + 1) * Rnd + lowerbound)
Next[/b][/color]
[color=#800000][b]If Browser("...").Page("...").WebEdit("...").GetROProperty("value")=CatEventCode Then
Reporter.ReportEvent micPass,"2 digits value is entered in <CAT/EvenetCode> field",""
Call Logger(1," 2 digits value is entered in <CAT/EvenetCode> field")
else
Reporter.ReportEvent micFail,"2 digits value is not entered in <CAT/EvenetCode> field",""
Call Logger(2,"2 digits value is not entered in <CAT/EvenetCode> field")
End If
Why does verification fail?
Any other idea for generating 2 digits unique number?