| re: One last WebBrowser DOM question...
There may be an easier way than this but offhand:
You can always get anything with "all". From the
all element collection, in a loop, you can look for
elements with tagName = "INPUT", then find the
one with the right name property. They also have
a "type" property. (Text, Password, etc.)
[color=blue]
> One last question and I will have my application working the way that I
> need...
>
> How can you put a value into a specific field on a specific form?
>
> If you look at the webpage sample below you will see that there are three
> forms on the page. Each form has a unique name, but the input tags are
> duplicated on each form.
>
> How would I (for example) assign the value "Bob" to the input box named
> "username" on the form named "FormTwo" in VB6 using the WebBrowser DOM???
>
> <html>
> <head>
> </head>
> <body>
> <form name="FormOne" action = "">
> Name: <input type="text" name ="username"> <br>
> Password: <input type="password" name="password"><br>
> <input type="submit" name="submit">
> </form>
> <hr>
> <form name="FormTwo" action = "">
> Name: <input type="text" name ="username"> <br>
> Password: <input type="password" name="password"><br>
> <input type="submit" name="submit">
> </form>
> <hr>
> <form name="FormThree" action = "">
> Form3<br>
> Name: <input type="text" name ="username"> <br>
> Password: <input type="password" name="password"><br>
> <input type="submit" name="submit">
> </form>
> </body>
> </html>
>
>[/color] |