• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 721
  • Last Modified:

TextBox vs input

I have a field <input  runat ="server" id="email" ..>

This is in a formview. I want to find that control...can I use a Textbox to find it
TextBox email = frmContact.FindControl("email") as TextBox;

Or HTMLControl something?
1 Solution
Shaun KlineLead Software EngineerCommented:
If you can, you might want to change the control <asp:TextBox ...>.
Shaun KlineLead Software EngineerCommented:
However, if the input type equals text, it should equate to and HTML Control for the text box.
CamilliaAuthor Commented:
what if i dont want to use a textbox...what is the control for "input". HTMLxxx??
Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Saqib KhanSenior DeveloperCommented:
input itself is nothing really.."Type" attribute is required.
<input type="text">
<input type="button">

runat=server attribute makes your controls to be accessed via .Net FrameWork
CamilliaAuthor Commented:
i just tried TextBox" and it cant find the control. I do have type="text". But seems like I cant use a TextBox...So it's HTML something?? HTMLInput maybe??
CamilliaAuthor Commented:
yes, it's HtmlInputText
A textbox in HTML is an input of type text.

HTML Textbox = <input type="text" />

Also, an <asp:Textbox> control renders a <input type="text" />
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Keep up with what's happening at Experts Exchange!

Sign up to receive Decoded, a new monthly digest with product updates, feature release info, continuing education opportunities, and more.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now