Jump to content

_IEFormelementRadioSelect (button state) without Form


Krmat
 Share

Go to solution Solved by Danp2,

Recommended Posts

Hi All!

I'm struggling with this page I want to automate. The formelements, like buttons, textarea's and radio buttons are being called by Javascript..

Through searching for Tags on the whole page, I found most elements I was looking for, a lot of wich I can manipulate with for example using _IEFormElementGet & SetValue, or _IEAction.

But i came across with these radio buttons I need to automate (just need to get the state of them, if its selected or not). There is no FORM on this page, so i can't use _IEFormElementRadioSelect($oForm, 0, "radioExample", -1, "byIndex") to get the state of them, i can manipulate them using _IETagNameGetCollection and _IEAction.

How do I check the state these radiobuttons? If I have to use _IEFormElementRadioSelect, how do I find the correct "$oForm" without one? I have already check the examples to make sure that there is no FORMs.

Local $oIE = _IEAttach ("")

Local $oFrames = _IEFrameGetCollection($oIE, 0) ; Select first frame

Local $oObj = _IEGetObjById($oFrames, "__RECORD_LINK_1__")

Local $radiobutton1 = _IETagNameGetCollection($oObj, "input", 1)

_IEAction($radiobutton1, "click") ; I can select the radio button if i want to, but i need to check the state because some of them come already selected.

Thanks in advance!  :thumbsup: 

Link to comment
Share on other sites

Thx Danp2. Solved my problem.

Just put the ".checked" and it will return "True" or "False" state (exactly what i want)

Local $oIE = _IEAttach ("")

Local $oFrames = _IEFrameGetCollection($oIE, 0) ; Select first frame

Local $oObj = _IEGetObjById($oFrames, "__RECORD_LINK_1__")

Local $radiobutton1 = _IETagNameGetCollection($oObj, "input", 1)

MsgBox($MB_SYSTEMMODAL, "Element Check State", $radiobutton1.checked) ;Working thx to Danp2 XD
Link to comment
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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...