Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Implementing If...Else on Web Page
#8
Macro Macro2333
Code:
Copy      Help
,int w3=win("Internet Explorer" "IEFrame")
,Htm e50=htm("INPUT" "rbnTrue1" "" w3 "0" 3 0x101)
,if e50 ;;page "Question Time! -*"
,,e50.Click
,,wait 0.25
,,Htm e22=htm("INPUT" "btnSubmit" "" w3 "0" 5 0x121 3)
,,e22.Click
,else
,,Htm e18=htm("INPUT" "btnNext" "" w3 "0" 15 0x101)
,,if e18 ;;page "select_product -*"
,,,e18.Click
,,else
,,,mes "error"

this also waits, max 5 s
Macro Macro2333
Code:
Copy      Help
,int found=0
,int w3=win("Internet Explorer" "IEFrame")
,rep 10
,,Htm e50=htm("INPUT" "rbnTrue1" "" w3 "0" 3 0x101)
,,if e50 ;;page "Question Time! -*"
,,,e50.Click
,,,wait 0.25
,,,Htm e22=htm("INPUT" "btnSubmit" "" w3 "0" 5 0x121 3)
,,,e22.Click
,,,found=1; break
,,else
,,,Htm e18=htm("INPUT" "btnNext" "" w3 "0" 15 0x101)
,,,if e18 ;;page "select_product -*"
,,,,e18.Click
,,,,found=2; break
,,,else
,,,,0.5
,if(!found) mes "error"


Messages In This Thread

Forum Jump:


Users browsing this thread: 2 Guest(s)