Accessing getElementById in c#

  • Thread starter Thread starter AAJ
  • Start date Start date
A

AAJ

Hi all

is it possible to replace the following javascript with an equivalent on the
server side c#

<script type="text/javascript" >
var txt1 = document.getElementById("txtProblem");
txt1.title = "Enter the description of the problem.";
</script>

thanks

Andy
 
If your control is declared as <input id="txtProblem" runat="server">, you
could just use txtProblem.Attribute.Add("title", "Enter the description of
the problem.");
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top