How To Auto Click Button in vb.net
button of

<input name="ctl00$ContentPlaceHolder1$imgBtnConvert2VB" id="ctl00_ContentPlaceHolder1_imgBtnConvert2VB" title="Convert to VB.Net" src="images/cs2vb.jpg" alt="Convert to VB.Net" onclick='javascript:WebForm_DoPostBackWithOptions(new WebForm_PostBackOptions("ctl00$ContentPlaceHolder1$imgBtnConvert2VB", "", true, "", "", false, false))' style="border-width:0px;" type="image">


<a id="ctl00_contentHolderBody_btnConvert" class="buttonOrange" href='javascript:WebForm_DoPostBackWithOptions(new WebForm_PostBackOptions("ctl00$contentHolderBody$btnConvert", "", true, "Convert", "", false, true))'>Convert Code »</a>


<a class="ctl00_cphBody_ctl00_Menu1_1 tab ctl00_cphBody_ctl00_Menu1_3" href="javascript:__doPostBack('ctl00$cphBody$ctl00$Menu1','1')" style="border-style:none;font-size:1em;">Convert C# to VB.Net</a>


<id="submit" class="button" value="Convert Code" tabindex="7" type="submit">

How do you know when to auto-click the button?

I just use

btnMyButton.PerformClick()

How to click a button webbrowser
<input name="ctl00$ContentPlaceHolder1$imgBtnConvert2VB" id="ctl00_ContentPlaceHolder1_imgBtnConvert2VB" title="Convert to VB.Net" src="images/cs2vb.jpg" alt="Convert to VB.Net" onclick='javascript:WebForm_DoPostBackWithOptions(new WebForm_PostBackOptions("ctl00$ContentPlaceHolder1$imgBtnConvert2VB", "", true, "", "", false, false))' style="border-width:0px;" type="image">

webBrowser1.Document.All("Button ID").InvokeMember("click")
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.