Extending a 3rd party control

Discussion in 'ASP .Net Building Controls' started by Randy, Dec 27, 2004.

  1. Randy

    Randy Guest

    I'm trying to extend the Infragistics Webcombo. I create my own server
    control and set all
    the properties that I want to standardize on in the constructor. However,
    drag my control onto the design view of my aspx page, it puts all
    the original properties in the html. For example, I want all my drop
    downs to be 80px wide. So I want to
    default this in the constructor but allow developers to override if need be.
    However, now the html properties have a value of 200px.

    Is there anyway to tell the server control to not pull in properties into
    the html?

    -Randy
    Randy, Dec 27, 2004
    #1
    1. Advertising

  2. Randy

    Rico Guest

    Randy,

    I have been working the several past few days with Infragistics, and
    extending two of their controls in my own composite control. I have not
    experienced this problem though, however i think that you are doing
    something wrong when you're rendering the controls, or that you define
    your properties incorrectly.
    This is an example how i define a property:

    <Bindable(True), Category("MinTabb"), DefaultValue(""),
    Description("tb_Tree_itemtype.intTypeId will be equaled to this
    integer.")> Public Property [GetWhereTypeIdEquals]() As Integer
    Get
    Return Me._GetWhereTypeIdEquals
    End Get
    Set(ByVal Value As Integer)
    Me._GetWhereTypeIdEquals = Value
    End Set
    End Property

    And later in:
    Protected Overrides Sub CreateChildControls()
    'i use the property (if it is set) like this:
    If me.GetWhereGroupIdEquals <> 0 then '.... you get the idea ..
    Rico, Dec 29, 2004
    #2
    1. Advertising

  3. Randy

    Randy Guest

    Rico,

    I'm not even adding my own properties. I'm only trying to set defaults for
    the standard properties of the webcombo control. e.g. in the constructor
    I'll do something like this.

    this.Width = 50;


    However, when I add the control to my page, it sets the width property in
    the html to 200, nullifying my constructor change.

    -Randy


    "Rico" <> wrote in message
    news:...
    > Randy,
    >
    > I have been working the several past few days with Infragistics, and
    > extending two of their controls in my own composite control. I have not
    > experienced this problem though, however i think that you are doing
    > something wrong when you're rendering the controls, or that you define
    > your properties incorrectly.
    > This is an example how i define a property:
    >
    > <Bindable(True), Category("MinTabb"), DefaultValue(""),
    > Description("tb_Tree_itemtype.intTypeId will be equaled to this
    > integer.")> Public Property [GetWhereTypeIdEquals]() As Integer
    > Get
    > Return Me._GetWhereTypeIdEquals
    > End Get
    > Set(ByVal Value As Integer)
    > Me._GetWhereTypeIdEquals = Value
    > End Set
    > End Property
    >
    > And later in:
    > Protected Overrides Sub CreateChildControls()
    > 'i use the property (if it is set) like this:
    > If me.GetWhereGroupIdEquals <> 0 then '.... you get the idea ..
    >
    Randy, Dec 29, 2004
    #3
    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. BestNews

    Any 3rd party Grid control in dotnet

    BestNews, Aug 26, 2003, in forum: ASP .Net
    Replies:
    4
    Views:
    5,169
    Robert Jacobson
    Aug 26, 2003
  2. =?Utf-8?B?QnJlbmRlbiBCaXhsZXI=?=

    Weekly view for Calendar control or 3rd Party component

    =?Utf-8?B?QnJlbmRlbiBCaXhsZXI=?=, Apr 3, 2006, in forum: ASP .Net
    Replies:
    4
    Views:
    7,320
    veezeet
    Oct 17, 2007
  3. perplexed

    3rd party AJAX tab control

    perplexed, Jan 30, 2007, in forum: ASP .Net
    Replies:
    1
    Views:
    366
    Eliyahu Goldin
    Jan 30, 2007
  4. sandal
    Replies:
    8
    Views:
    282
    Mark Rae [MVP]
    Oct 16, 2007
  5. Tim
    Replies:
    0
    Views:
    200
Loading...

Share This Page