QTP TIP – the random selection WebRadioGroup option

Posted on Dec 20 2012 - 8:10am by Raj

1, randomly select the drop-down options:
‘Get the number of options
t = Browser (“Browser”) Page (“User Management”). WebRadioGroup (fingerprint authentication). GetROProperty (“items count”)
‘Get a random index of the item
b = RandomNumber (0, t2-1)
‘Set random option
Browser (“Browser”). (“User Management”). WebRadioGroup (fingerprint authentication) Select “#” & b

2, printout options
m = m2 = Browser (“Browser”) Page (“User Management”). WebRadioGroup (fingerprint authentication). GetROProperty (“value”)
MsgBox m

About the Author

Leave A Response