ASPForums.Net RSS Feedhttp://www.aspforums.net/Handlers/RSS.ashxLatest additions to the content that appears on ASPForums.Net(c) 2019 www.aspforums.com. All rights reserved.Call Server Side event from HTML Button click<p>Hi <a class="username" rel="chetan"> chetan</a>,</p> <p>Your code is working.</p> <p>Refer below sample.</p> <p><strong><span style="text-decoration: underline;">HTML</span></strong></p> <pre class="brush: html">&lt;asp:TextBox runat=&#34;server&#34; ID=&#34;txtName&#34; /&gt; &lt;br /&gt; &lt;input class=&#34;dt-header-search-submit dt-button dt-button-danger&#34; type=&#34;button&#34; value=&#34;Search&#34; style=&#34;top: 1px; width: 225px;&#34; runat=&#34;server&#34; onserverclick=&#34;doit&#34; /&gt;</pre> <p><strong><span style="text-decoration: underline;">C#</span></strong></p> <pre class="brush: csharp">protected void doit(object sender, EventArgs e) { ClientScript.RegisterClientScriptBlock(this.GetType(), &#34;&#34;, &#34;alert(&#39;Name is : &#34; + txtName.Text.Trim() + &#34;&#39;)&#34;, true); }</pre> <p><strong><span style="text-decoration: underline;">Screenshot</span></strong></p> <p><img src="https://i.imgur.com/u9wEbDQ.jpg" alt="" width="428" height="166" /></p>https://www.aspforums.net:443/Threads/502455/Call-Server-Side-event-from-HTML-Button-click/https://www.aspforums.net:443/Threads/502455/Call-Server-Side-event-from-HTML-Button-click/Wed, 26 Sep 2018 00:02:36 GMT