Kenneth

Kenneth

  • NA
  • 5
  • 6k

Webbrowser; select radio button

Apr 27 2011 11:01 AM

Hi,

I am making an autofill-program, and have some issues with selecting radiobuttons. I use Visual C# 2010 express edition.

Normally I just use getelementsbyid, setattribute and invokemember, but I don't see how I can select a radiobutton without id. Maybe I need to edit the html to make a radiobutton checked, and then just use invokemember to submit?

</tr>
       
<tr>
       
<td><input type="radio" name="x1"  value="ve"> Vero</td>
       
</tr>
       
       
<tr>
       
<td><input type="radio" name="x1" value="ee"> Eee</td>
       
</tr>
       
       
<tr>
       
<td><input type="radio" name="x1" value="wa"> Walla</td>
       
</tr>
       
       
<tr>
       
<td><input type="radio" name="x1" value="qu"> Quack</td>
       
</tr>
       
<tr>


As you see, there is no default select.
I'am new to C# so I don't know what it can do, but it would be cool to learn how to edit websites html through C#. I really just need to add "checked" to one of them radiobutton. I have a lot of experience with html, so if I can find out how I can use C# to find and insert code; it would be great.





Best Regards
Kenneth

Answers (4)