Problem with LinkButton and AddAttributesToRender

Discussion in 'ASP .Net Building Controls' started by Henri, Oct 3, 2004.

  1. Henri

    Henri Guest

    Hi,

    I'm trying to design a custom LinkButton.
    It inherits LinkButton as I need the implementation of the Click event (and
    I don't know how to rewrite it).
    I have to use AddAttributesToRender to render all the style attributes and
    properties.
    But as I want to specifie my own href attribute, I can't use LinkButton's
    default AddAttributesToRender as it automatically adds its own href
    attribute.
    It would be great if I could call only WebControl's AddAttributesToRender
    (LinkButton's parent class) but it doesn't seem possible to call it from my
    class as it inherits LinkButton.
    So do I need to rewrite completely WebControl's AddAttributesToRender
    implementation to get rid of the href attribute added by LinkButton?
    Do you have any solution?
    Thanks

    Henri
     
    Henri, Oct 3, 2004
    #1
    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. Henri
    Replies:
    2
    Views:
    756
    Henri
    Oct 5, 2004
  2. Sathyaish
    Replies:
    3
    Views:
    3,152
    Sathyaish
    Sep 8, 2005
  3. Paul L

    Custom CheckBox class not calling AddAttributesToRender

    Paul L, Mar 17, 2005, in forum: ASP .Net Building Controls
    Replies:
    0
    Views:
    140
    Paul L
    Mar 17, 2005
  4. TS

    checkboxlist "AddAttributesToRender"

    TS, Feb 16, 2009, in forum: ASP .Net Building Controls
    Replies:
    6
    Views:
    1,367
  5. Sathyaish

    Linkbutton does not look like a linkbutton

    Sathyaish, Sep 8, 2005, in forum: ASP .Net Datagrid Control
    Replies:
    1
    Views:
    207
    Sathyaish
    Sep 8, 2005
Loading...

Share This Page