|
-
Apr 16th, 2001, 11:49 AM
#1
How do I set a radio value ?
I.e. WebBrowser1.Document.Forms(0).radioname.Value = "Option1"?
The HTML is:
<INPUT TYPE="RADIO" NAME="O_T" VALUE="O" >O
<INPUT TYPE="RADIO" NAME="O_O" VALUE="T" >T
-
Apr 16th, 2001, 01:11 PM
#2
Addicted Member
<INPUT TYPE="RADIO" NAME="O_T" VALUE="O" checked>
You can also do this in VBScript. This requires a browser which supports DHTML. To do this you must have the input tag inside div tags.
<div id=test>
<INPUT TYPE="RADIO" NAME="O_T" VALUE="0">
</div>
To turn it on use the following code:
Code:
test.InnerHtml = "<INPUT TYPE=""RADIO"" NAME=""O_T"" VALUE=""0"" CHECKED>"
To turn it off use:
Code:
test.InnerHtml = "<INPUT TYPE=""RADIO"" NAME=""O_T"" VALUE=""0"">"
Hope that helped.
-
Apr 16th, 2001, 01:23 PM
#3
Thanks but I would like to do it in VB using the webbrowser control what I do for text is:
WebBrowser1.Document.Forms(0).textboxname.Value = "Whatever"
can you tell me how to do that with radio/checkboxes?
-
Apr 16th, 2001, 01:35 PM
#4
Addicted Member
Then you can use:
Code:
WebBrowser1.document.forms("test").R1.checked = false
-
Apr 17th, 2001, 06:31 AM
#5
Thanks, that works for a checkbox, what about a radio?
-
Apr 18th, 2001, 05:06 AM
#6
Addicted Member
It is the same for radio.
-
Apr 18th, 2001, 08:50 AM
#7
sorry, but it doesn't work, and I can't use it for a radio like:
<INPUT TYPE="RADIO" NAME="O_T" VALUE="O" >O
<INPUT TYPE="RADIO" NAME="O_T" VALUE="T" >T
webbrowser1.forms(0).O_T.????
-
Apr 18th, 2001, 10:02 AM
#8
Addicted Member
Code:
WebBrowser1.document.forms("test").O_T.checked = false
-
Apr 18th, 2001, 10:28 AM
#9
Thanks, but what I want to know is how to choose one of them (O or T).
And one more question, I've suceeded in loging into yahoo mail and getting into the inbox throught webbrowser in vb but I would like to know how I can open a cerin message titled "Yahoo!" (welcome to yahoo message), can I do something like:
webbrowser1.document.forms(0).("Yahoo!").click ?
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|