Hi,
R.A.M. said:
Hello,
I am learning .NET 2.0. And I have a question: when to use web-controls and
when to use HTML controls?
/RAM/
The System.Web.UI.HtmlControls namespace is for HTML controls, in the
sense that they are declared on the page using standard HTML tags, for
example "input", "select", "textarea", etc...
The System.Web.UI.WebControls namespace is for ASP.NET controls, which
are declared on the page with an "asp:" prefix, for example "asp:Checkbox".
The different is that in the first case, they're client-side controls.
You use them on the server in order to set attributes, scripts, etc...
which are executed on the client. In the second case, however, (and
while you can also influence the way they will be rendered on the
client), the events you wire them to are executed on the server
(involving a postback).
HTH,
Laurent