Sign in to follow this  
Followers 0
faustf

_iaction click , not clik :)

3 posts in this topic

hi  guy  

i  have  a  button in web  page ,  the  button is  like  menu-button  (click and  scroll down a curtain with dynamic link inside )

this is  a code  

<div class="btn-group open" abp="154">
  <a class="btn btn-small btn-espriAzzurro lucido gradient dropdown-toggle" href="#" abp="155" data-toggle="dropdown">
     Mostra subito... 
     <span class="caret" abp="156"></span>
 </a>
<ul class="dropdown-menu" abp="157">
    <li abp="158">
       <a href="" abp="159" data-ng-click="CercaTop100($event,'/b2b/Ricerche')" data-ng-show="TotProdotti >
        LimiteProdotti">...i primi cento prezzi</a>
     </li>
<!-- ngRepeat: fascia in FascePrezzo -->
<li class="ng-scope" abp="160" data-ng-repeat="fascia in FascePrezzo">
   <a class="ng-binding" href="#" abp="161" data-ng-click="CercaPerPrezzo($event,fascia.Min,fascia.Max)">i prodotti da 
      10.63 a 70.52 euro</a>
</li>
<!-- end ngRepeat: fascia in FascePrezzo -->
<li class="ng-scope" abp="160" data-ng-repeat="fascia in FascePrezzo">
   <a class="ng-binding" href="#" abp="161" data-ng-click="CercaPerPrezzo($event,fascia.Min,fascia.Max)">i prodotti da 
      70.52 a 146.3 euro</a>
</li>
<!-- end ngRepeat: fascia in FascePrezzo -->
<li class="ng-scope" abp="160" data-ng-repeat="fascia in FascePrezzo">
    <a class="ng-binding" href="#" abp="161" data-ng-click="CercaPerPrezzo($event,fascia.Min,fascia.Max)">i prodotti da 
       146.3 a 194 euro</a>
</li>
<!-- end ngRepeat: fascia in FascePrezzo -->
  <li class="ng-scope" abp="160" data-ng-repeat="fascia in FascePrezzo">
    <a class="ng-binding" href="#" abp="161" data-ng-click="CercaPerPrezzo($event,fascia.Min,fascia.Max)">i prodotti da 
      194 a 777.5 euro</a>
</li>
<!-- end ngRepeat: fascia in FascePrezzo -->
</ul></div>

i try to   clicked it  but  with unsucces

this  is  a my code 

Local $oFound = ""
Local $oBtns =  _IETagNameAllGetCollection($oIE)

For $oBtn In $oBtns
    If String($oBtn.classname) = "btn btn-small btn-espriAzzurro lucido gradient dropdown-toggle" Then
     $oFound = $oBtn
   EndIf
Next

If IsObj($oFound) Then
    Local $obtn = _IEFormElementGetObjByName($oIE, $oFound.id) ; Get ID of the button
  $oFound.fireEvent("onmousedown")
$oFound.fireEvent("onmouseup")
_IEAction($oFound, "click")
    MsgBox(16, "Success", "clikked")
Else
    MsgBox(16, "Failed", "Not found.")
EndIf

  the  code   "go  good" pop up a  msgbox , but  action click  not  do nothing 

someone  have  idea?? or  suggestion ??

thanks  at all 

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

Simplified...post the output:

Local $oBtns =  _IELinkGetCollection($oIE)

For $oBtn In $oBtns
    $classname = String($oBtn.classname())
    ConsoleWrite($classname & @CRLF)
    If $classname = "btn btn-small btn-espriAzzurro lucido gradient dropdown-toggle" Then
        ConsoleWrite("Found it" & @CRLF)
        _IEAction($oBtn,"Focus")
        $b = _IEAction($oBtn,"Click")
        ConsoleWrite("ie click return=[" & $b & "]." & @CRLF)
        ExitLoop
   EndIf
Next
Edited by jdelaney
1 person likes this

IEbyXPATH-Grab IE DOM objects by XPATH IEscriptRecord-Makings of an IE script recorder ExcelFromXML-Create Excel docs without excel installed GetAllWindowControls-Output all control data on a given window.

Share this post


Link to post
Share on other sites

you are  my hero  :)  it  open 

the  output 

label
btn-fantaricerca
btn-produttore
btn-comparti

Share this post


Link to post
Share on other sites

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
Sign in to follow this  
Followers 0