Jump to content

Recommended Posts

Posted

Dear Colleagues,

I have no idea how to refer to style.display in my loop. There is a button like: 

<input name="ctl00$bodyPlaceholder$btnFecharProcessamento" class="button" id="bodyPlaceholder_btnFecharProcessamento" style="display: none;" onclick="FecharJanelaProcessamento();return false;" type="submit" value="Fechar">

I want it to be clicked as soon as button's style change from style="display: none;" to  style= ="display: inline-block;" 

This is what I got, but it's not working...

Func GetButtons()
$oButtons = _IEGetObjByName($oForm,"ctl00$bodyPlaceholder$btnFecharProcessamento",-1)
$i = 0
While $i <> 1
For $oBtn In $oButtons
    If _IEFormElementGetValue($oBtn) = "Fechar" And $oBtn.document.style.display = "display: inline-block;" Then
       $i = 1
        _IEAction($oBtn, "focus")
        _IEAction($oBtn, "click")
        ExitLoop
    EndIf
 Next
 WEnd
EndFunc

 

I will really appreciate if you could help me with these loop!

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...