Re: How we define runat="server"



You do not have to use runat="server" on everything. You can, if you are merely working client side, use HTML controls rather than server controls. But, as soon as you try to fill the control from code behind, you will have to add the runat. For server controls, you do have to set runat, as the command has to be rendered and control servers side. This has to do with the inheritance tree of the control and how it is internally set up.

--
Gregory A. Beamer
MVP; MCP: +I, SE, SD, DBA

*********************************************
Think outside the box!
*********************************************
<gunjan.mait@xxxxxxxxx> wrote in message news:1174396792.663117.68650@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
hi,
i wanted to know the exact use of runat="server" which is being used
is ASP.NET
why we every time need to use it, even when i want to do the work at
client side? How to do simple processings like displaying some message
at client side only without hitting server?

what is the use of onclick, as we have to use onserverclick always?
why it is not possible to do the things without using runat="server"
in script?

what is the exact difference between coding at client-side and coding
at server-side?

In ASP.NET, there are two forms design form and code-behind form and
several controls.
what is the difference between HTML and webforms controls?
because we hav to include runat="server" while dealing with HTML
controls.


.



Relevant Pages

  • Re: VB.net and ASP.Net Typed Datasets
    ... upgraded the "backend" or data layer to SQL Server 2005. ... For these reasons we wish to use ASP.net, to have a Smart Client. ... inadequacies with the web controls and the winform. ... used in any .NET language. ...
    (microsoft.public.dotnet.framework.adonet)
  • Re: Client Side - click radio button - controls become enabled
    ... web controls on server side or className property on client side. ... > Thanks Eliyahu. ... I have two 'sets' of controls on a page. ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: Controls v HTML
    ... System.Web.UI.ICallbackEventHandler you can talk to the server from client ... script and any html element can not do as any asp.net control. ... controls with JavaScript? ... > programmatically in an OOP fashion. ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: Controls v HTML
    ... System.Web.UI.ICallbackEventHandler you can talk to the server from client ... script and any html element can not do as any asp.net control. ... controls with JavaScript? ... programmatically in an OOP fashion. ...
    (microsoft.public.dotnet.framework.aspnet)
  • the most efficient way get an answer for each of them would be to:
    ... Access or SQL Server database. ... > 6) WHAT ARE THE TYPES OF ASSEMBLIES? ... > 21) DIFFERNCE BETWEEN asp.net SERVER CONTROLS AND HTML ... > namespace used for this?. ...
    (microsoft.public.cert.exam.mcsd)