Jump to content
Sign in to follow this  
KonnectTest

How to click tab in browser

Recommended Posts

KonnectTest

Using "Developer Tools" I've found this information on a tab control being used on our website. How can I send a click command to the "Products" tab?

<A id=linkProducts class=tabControlDefaultNavigatorItem onclick="return expandContent(this)" href="#" ifeid="200" ifetype="container" disabledNavigatorItemClass="tabControlDefaultDisabledNavigatorItem" defaultDisabledNavigatorItemClass="tabControlDefaultDisabledNavigatorItem" defaultTab="false" disableonload="" tabNavigator_SelectedNavigatorItemClass="tabControlDefaultSelectedNavigatorItem" tabNavigator_DefaultSelectedNavigatorItemClass="tabControlDefaultSelectedNavigatorItem" tabNavigator_NavigatorItemClass="tabControlDefaultNavigatorItem" tabNavigator_DefaultNavigatorItemClass="tabControlDefaultNavigatorItem" tabNavigator_TabContentClass="" tabNavigator_DefaultContentClass="tabControlDefaultContent" tabGroupID="38" tabID="200" isTabHeading="true">

<DIV>Products </DIV></A>

Share this post


Link to post
Share on other sites
Steveiwonder

You don't need to have a tab "active" to be able to interact with it, AFAIK.

I've got two tabs open www.google.com and www.bing.com i've selected Bing and ran this code.

#include <ie.au3>

$oIE = _IEAttach("Google")
$oForm = _IEFormGetObjByName($oIE, "f")
$oQuery = _IEFormElementGetObjByName($oForm, "q")
_IEFormElementSetValue($oQuery, "AutoIt IE.au3")
_IEFormSubmit($oForm)

Not sure if this is what your looking for?

Edited by Steveiwonder

They call me MrRegExpMan

Share this post


Link to post
Share on other sites
KonnectTest

You don't need to have a tab "active" to be able to interact with it, AFAIK.

I've got two tabs open www.google.com and www.bing.com i've selected Bing and ran this code.

#include <ie.au3>

$oIE = _IEAttach("Google")
$oForm = _IEFormGetObjByName($oIE, "f")
$oQuery = _IEFormElementGetObjByName($oForm, "q")
_IEFormElementSetValue($oQuery, "AutoIt IE.au3")
_IEFormSubmit($oForm)

Not sure if this is what your looking for?

No, this is no good I'm afraid. You have the name of the tab and I don't ... well not from the information I posted in my first post.

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  

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.