Sign in to follow this  
Followers 0
elmoi0010

Clicking on "DIV" Tag.

11 posts in this topic

Hello guys, am back to the comunity<3.. Well i have a problem triying to click a button in a "DIV" tag..

screenshot_111.png

But there is another problem. There is another "btn3" in other "DIV" button look.

screenshot_112.png

Anyone can help me? Thanks in advanced.

Share this post


Link to post
Share on other sites



1.  There is no representation code that you've supplied that is failing.

2.  No idea what you're accessing (a browser?).

3.  No idea what methods you're using to access.

A simple guess, and as much information as you provided would result in the below synopsis.

Step through the all the tag names that are of "class".

Get their value

Depending on what you're using to access the data, the items you're stepping through are probably already objects, so use whatever method you use for other items to click.


Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Share this post


Link to post
Share on other sites

#3 ·  Posted (edited)

1.  There is no representation code that you've supplied that is failing.

2.  No idea what you're accessing (a browser?).

3.  No idea what methods you're using to access.

A simple guess, and as much information as you provided would result in the below synopsis.

Step through the all the tag names that are of "class".

Get their value

Depending on what you're using to access the data, the items you're stepping through are probably already objects, so use whatever method you use for other items to click.

 

Oh sorry i got the code here is it, and is not falling i just get two poop ups with the name of the buttons in the divs.. 

$oDivs = _IETagNameGetCollection ($amf_IE, "div")
For $oDiv in $oDivs
If $oDiv.classname == 'btn3' Then
MsgBox(0,"",$oDiv.classname)
ExitLoop
EndIf
EndIf
Next 

Thanks in advanced and sorry.

Edited by elmoi0010

Share this post


Link to post
Share on other sites

Yes, that's what my assumption was. You've done the classname bit, now you must get it's value so you know which to click.


Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Share this post


Link to post
Share on other sites

Yes, that's what my assumption was. You've done the classname bit, now you must get it's value so you know which to click.

Something like get the two pop ups in an array? Then click the second array? Something like..

 

$oDivs = _IETagNameGetCollection ($amf_IE, "div")
For $oDiv in $oDivs
    If $oDiv.classname == 'btn3' Then
            $Arr[3]
$arr[1] = Add new site/Page
Arr[2] = Like
_IEaction($Arr[2],"click")
            ExitLoop
        EndIf
    EndIf
Next

Can you help me?

Share this post


Link to post
Share on other sites

I've no idea what you're referring to with "Popup".  That was not in your original post.

When you're unable to explain in detail exactly what is going on (step by step), then you need to provide a link to what you're working on. and what you're trying to accomplish with that link.

It gets increasingly difficult to assist when new items are working their way in each post that could cause potential issues.

So either provide step by step what is going on (maybe even with screen shots), a link to the site and what you're trying to accomplish so we can recreate the issue ourselves, or code with detailed comments of where it is failing, and why you think it may be failing.


Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Share this post


Link to post
Share on other sites

I've no idea what you're referring to with "Popup".  That was not in your original post.

When you're unable to explain in detail exactly what is going on (step by step), then you need to provide a link to what you're working on. and what you're trying to accomplish with that link.

It gets increasingly difficult to assist when new items are working their way in each post that could cause potential issues.

So either provide step by step what is going on (maybe even with screen shots), a link to the site and what you're trying to accomplish so we can recreate the issue ourselves, or code with detailed comments of where it is failing, and why you think it may be failing.

.. Thanks for you help bro.

Share this post


Link to post
Share on other sites

no working for me.....

Share this post


Link to post
Share on other sites
Local $oInputs = _IETagNameGetCollection($Adds, "div")
For $oInput In $oInputs
    If $oInput.classname == "btn3" Then _IEAction($oInput, "click")
 
Next
 
 
its problem is next !
 
need it stops for a few seconds until the pop up open and close the event takes place, then run the next turning the same page pop up, is?
 
help me please
my email pxlove@hotmail.com

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