Is there any possibility to initialize the value of the fields of standard HTML controls from C # code when the page loads?

such as

<select class="form-control" id="mySelect" name="mySelect"> <option selected>val1</option> <option>val2</option> </select> 
  • 2
    What's the problem? runat="server" and go ... - Pavel Mayorov
  • Moreover, runat="server" used in the standard html elements as well as in the <asp:...> elements. If you remove the runat="server" element from the <asp:...> element, it will not stop working, since all asp elements are converted to html markup. Try running the site on asp.net and see the исходный текст ! - Egor Trutnev

0