Sign in to follow this  
Followers 0
HighlanderSword

Working with Ie and Tabs

4 posts in this topic

Hello,

When working with tabs in IE , how do you select the tab you want, to manually do it I would just click the tab name , I have tried

_IEImgClick

$oIE = _IEAttach("Changes")

_IEImgClick ($oIE, "Plans", "alt")

This appears to do nothing , when i use debugbar I'm able to get the details below

<A class="text tton " onmousedown="input_mousedown(event, this);cancelEvent(event);" id=mx203_anchor onmouseover="return noStatus()" title=Plans onfocus="setCurrentfocusId(event, this);" href="javascript: tabClick('mx203');">&nbsp;Plans</A>

Any suggestions would be greatly appreciated

Thanks

Paul

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

Hello,

When working with tabs in IE , how do you select the tab you want, to manually do it I would just click the tab name , I have tried

_IEImgClick

$oIE = _IEAttach("Changes")

_IEImgClick ($oIE, "Plans", "alt")

This appears to do nothing , when i use debugbar I'm able to get the details below

<A class="text tton " onmousedown="input_mousedown(event, this);cancelEvent(event);" id=mx203_anchor onmouseover="return noStatus()" title=Plans onfocus="setCurrentfocusId(event, this);" href="javascript: tabClick('mx203');">&nbsp;Plans</A>

Any suggestions would be greatly appreciated

Thanks

Paul

_IEAttach() can attach to tabs in IE7 (and IE8, I presume). The default match type is document title (note that is different from window title), so are you sure the document title for that tab is "Changes"? If not, have you tried some of the other modes?

>_<

Edited by PsaltyDS

Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law

Share this post


Link to post
Share on other sites

Hello,

Yes I'm sure the window Title is Changes, I'm doing several other things with the items in the window, its just that there are tabs on the window

that I need to somehow automate the click, I'm trying to avoid using the mousemove, as the script I'm creating will be run on

several differnt machines all with differnt screen resolutions.

Below is a sample

$oIE = _IEAttach("Changes")

$test= mxnum("Summary")

$oInput = _IEGetObjById($oIE, $test)

_IEFormElementSetValue($oInput, "Test me")

Func mxnum($x)

; $oInputs = _IETagNameGetCollection ($oIE, "input")

$oInputs = _IETagNameGetCollection ($oIE, "TABLE")

For $oInput In $oInputs

;MsgBox(0, "Form Input Type", $oInput.type & " " & $oinput.id & " " & $oInput.title)

;MsgBox(0,"",$oInput.title)

if $oInput.title = $x Then

$gotit = $oInput.id

EndIf

Next

return ($gotit)

EndFunc

The above code woeks with n o problem on the window Titled Changes.

Any body have an ideas ?

Thanks

Paul

Share this post


Link to post
Share on other sites
Based on this post from Dale from January, I'm going to guess that you're not going to find manipulating tabs very workable...

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