VBA IE Javascript Radio Select

sskicker23

New Member
Joined
Jan 12, 2010
Messages
10
Hi Guys,

I am having a little trouble selecting a radio button on a webpage that has...alot of javascript fuctions. On a normal webpage I would execute the following codes:

Code:
IE.document.getElementById("selectedvariable")(11011).Checked = True

or the following:

Code:
Set radio_button = IE.document.all.Item("SelectedVariable")
For Each rb In radio_button
If rb.Value = "808725" Then
rb.Checked = True
End If

Lately I have been using a point and click program to help me identify form names, tag names, and values quicker. The program has genereate the following vb.net string which selects the radio button:
Code:
scene.HtmlInputRadioButton("TargetSelected").Invoke("Click", ControlActionType.InvokeMethod, "Target -2644426-2644366")

The HTML source code that I can find:
HTML:

The website has a bunch of information that I have to fill in. The Radio button comes from a pop up window( it is not a new browser window just a script window that populate with data from the parent tree. kind of hard to explain) <---- haha idk what im talking about. the pop window is executed by the following code:
Code:
Call IE.document.parentWindow.execScript("openSearchWindow('search')")

I have tried both of my methods listed above and both have failed.
I am having a little difficulting following all of the html but If I can provide any additional script please let me know.
I am open to any and all suggestion. Thanks again in advance.
</FORM>
 

Excel Facts

Copy PDF to Excel
Select data in PDF. Paste to Microsoft Word. Copy from Word and paste to Excel.
Sorry the HTML Code did not show:

Code:
Code:
[CODE]input name="TargetSelected" *******="setSelectedTarget(this)" type="radio" value="Target-2644426-2644366"/>
 
Last edited:
Upvote 0

Forum statistics

Threads
1,224,609
Messages
6,179,879
Members
452,948
Latest member
Dupuhini

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top