Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
MSIE OLE Automation and Radio Buttons
Message
From
16/08/1999 16:39:58
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Internet applications
Title:
MSIE OLE Automation and Radio Buttons
Miscellaneous
Thread ID:
00254261
Message ID:
00254261
Views:
64
I am having difficulty changing the value of a radio button on someone else's web page using OLE automation. Apparently you can't reference the individual radio button elements by name, because they all have the same name. This works OK with a text object, etc. because the names don't overlap.

In the Document Object Model entry for "children" is the following statement:
The elements contained in this collection are undefined if the child elements are overlapping tags. Similar to the "all" collection.

So how the heck do you reference a radio button using automation? Referencing it directly by name (not through a collection) doesn't work either. Any ideas?

Here is the section of automation code, plus a fragment of HTML from the page. The commented line of VFP5 code is the one that doesn't work (OLE Error: Unknown name).

Thanks.....

-------------------------

oMatrixFr = oIE.Document.Frames(1)
oMatrixFm = oMatrixFr.Document.Forms(0)

oMatrixFm.All("csenum").Value = "97-12345"
** oMatrixFm.All("typfmt").Value = "rawfrmt"

oMatrixFm.Submit


-------------------------

< FORM Method=POST TARGET="_top" Action="matrix.pl" NAME="clue" >






Select format:


1 column

3 column

raw data format




< /FORM >
Next
Reply
Map
View

Click here to load this message in the networking platform