difference between HtmlControls and WebControls?

Discussion in 'ASP .Net' started by Henri, May 17, 2004.

  1. Henri

    Henri Guest

    For instance, when should I use HtmlControls.HtmlImage,
    and when should I use WebControls.Image ?

    And what is the difference between
    <img runat="server" />
    and
    <asp:image runat="server" /> ?
    Henri, May 17, 2004
    #1
    1. Advertising

  2. The first example you gave <img runat="server"> is an HTML control.
    The second example you gave <asp:image runat="server" /> is a web control.

    HTML controls are quick and small and require little memory. Conversly, web
    controls provide more advanced functionality than HTML controls.

    If you're an old school HTML web developer then you'll find the HTML
    controls to be intuitive and familiar. If you have more of a
    Windows/VB/ActiveX background then you're more likely to feel at home with
    the extra features that web controls provide.

    --
    I hope this helps,
    Steve C. Orr, MCSD, MVP
    http://Steve.Orr.net





    "Henri" <> wrote in message
    news:%...
    > For instance, when should I use HtmlControls.HtmlImage,
    > and when should I use WebControls.Image ?
    >
    > And what is the difference between
    > <img runat="server" />
    > and
    > <asp:image runat="server" /> ?
    >
    >
    >
    Steve C. Orr [MVP, MCSD], May 18, 2004
    #2
    1. Advertising

  3. Henri

    Henri Guest

    Very clear, thanks a lot!
    :)
    To make a custom control, it seems that many control developpers inherit
    WebControls. What does it add more than inheriting HtmlControl or Control?

    Henri

    "Steve C. Orr [MVP, MCSD]" <> a écrit dans le message de
    news:%...
    > The first example you gave <img runat="server"> is an HTML control.
    > The second example you gave <asp:image runat="server" /> is a web control.
    >
    > HTML controls are quick and small and require little memory. Conversly,

    web
    > controls provide more advanced functionality than HTML controls.
    >
    > If you're an old school HTML web developer then you'll find the HTML
    > controls to be intuitive and familiar. If you have more of a
    > Windows/VB/ActiveX background then you're more likely to feel at home with
    > the extra features that web controls provide.
    >
    > --
    > I hope this helps,
    > Steve C. Orr, MCSD, MVP
    > http://Steve.Orr.net
    >
    >
    >
    >
    >
    > "Henri" <> wrote in message
    > news:%...
    > > For instance, when should I use HtmlControls.HtmlImage,
    > > and when should I use WebControls.Image ?
    > >
    > > And what is the difference between
    > > <img runat="server" />
    > > and
    > > <asp:image runat="server" /> ?
    > >
    > >
    > >

    >
    >
    >
    Henri, May 18, 2004
    #3
  4. HTML controls weren't designed to be extensible.
    Therefore, when making your own controls you should inherit from WebControl
    or Control.

    --
    I hope this helps,
    Steve C. Orr, MCSD, MVP
    http://Steve.Orr.net



    "Henri" <> wrote in message
    news:%...
    > Very clear, thanks a lot!
    > :)
    > To make a custom control, it seems that many control developpers inherit
    > WebControls. What does it add more than inheriting HtmlControl or Control?
    >
    > Henri
    >
    > "Steve C. Orr [MVP, MCSD]" <> a écrit dans le message de
    > news:%...
    > > The first example you gave <img runat="server"> is an HTML control.
    > > The second example you gave <asp:image runat="server" /> is a web

    control.
    > >
    > > HTML controls are quick and small and require little memory. Conversly,

    > web
    > > controls provide more advanced functionality than HTML controls.
    > >
    > > If you're an old school HTML web developer then you'll find the HTML
    > > controls to be intuitive and familiar. If you have more of a
    > > Windows/VB/ActiveX background then you're more likely to feel at home

    with
    > > the extra features that web controls provide.
    > >
    > > --
    > > I hope this helps,
    > > Steve C. Orr, MCSD, MVP
    > > http://Steve.Orr.net
    > >
    > >
    > >
    > >
    > >
    > > "Henri" <> wrote in message
    > > news:%...
    > > > For instance, when should I use HtmlControls.HtmlImage,
    > > > and when should I use WebControls.Image ?
    > > >
    > > > And what is the difference between
    > > > <img runat="server" />
    > > > and
    > > > <asp:image runat="server" /> ?
    > > >
    > > >
    > > >

    > >
    > >
    > >

    >
    >
    >
    Steve C. Orr [MVP, MCSD], May 18, 2004
    #4
  5. Henri

    Henri Guest

    Thanks :)

    "Steve C. Orr [MVP, MCSD]" <> a écrit dans le message de
    news:...
    > HTML controls weren't designed to be extensible.
    > Therefore, when making your own controls you should inherit from

    WebControl
    > or Control.
    >
    > --
    > I hope this helps,
    > Steve C. Orr, MCSD, MVP
    > http://Steve.Orr.net
    >
    >
    >
    > "Henri" <> wrote in message
    > news:%...
    > > Very clear, thanks a lot!
    > > :)
    > > To make a custom control, it seems that many control developpers inherit
    > > WebControls. What does it add more than inheriting HtmlControl or

    Control?
    > >
    > > Henri
    > >
    > > "Steve C. Orr [MVP, MCSD]" <> a écrit dans le message de
    > > news:%...
    > > > The first example you gave <img runat="server"> is an HTML control.
    > > > The second example you gave <asp:image runat="server" /> is a web

    > control.
    > > >
    > > > HTML controls are quick and small and require little memory.

    Conversly,
    > > web
    > > > controls provide more advanced functionality than HTML controls.
    > > >
    > > > If you're an old school HTML web developer then you'll find the HTML
    > > > controls to be intuitive and familiar. If you have more of a
    > > > Windows/VB/ActiveX background then you're more likely to feel at home

    > with
    > > > the extra features that web controls provide.
    > > >
    > > > --
    > > > I hope this helps,
    > > > Steve C. Orr, MCSD, MVP
    > > > http://Steve.Orr.net
    > > >
    > > >
    > > >
    > > >
    > > >
    > > > "Henri" <> wrote in message
    > > > news:%...
    > > > > For instance, when should I use HtmlControls.HtmlImage,
    > > > > and when should I use WebControls.Image ?
    > > > >
    > > > > And what is the difference between
    > > > > <img runat="server" />
    > > > > and
    > > > > <asp:image runat="server" /> ?
    > > > >
    > > > >
    > > > >
    > > >
    > > >
    > > >

    > >
    > >
    > >

    >
    >
    >
    Henri, May 18, 2004
    #5
    1. Advertising

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

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Gopal Prabhakaran

    Difference between HtmlControls and server controls

    Gopal Prabhakaran, Jan 26, 2004, in forum: ASP .Net
    Replies:
    1
    Views:
    2,413
    Rainer Maurer [MS]
    Jan 26, 2004
  2. Abhishek Srivastava

    WebControls and HtmlControls

    Abhishek Srivastava, May 12, 2004, in forum: ASP .Net
    Replies:
    0
    Views:
    381
    Abhishek Srivastava
    May 12, 2004
  3. R.A.M.

    2.0: WebControls vs HtmlControls

    R.A.M., Jun 6, 2006, in forum: ASP .Net
    Replies:
    0
    Views:
    326
    R.A.M.
    Jun 6, 2006
  4. Replies:
    4
    Views:
    650
  5. archana
    Replies:
    5
    Views:
    400
    Mark Rae
    Apr 11, 2007
Loading...

Share This Page