Property Grid: Attribute to only show non-inherited properties

Discussion in 'ASP .Net' started by Nathan Sokalski, Oct 14, 2009.

  1. I have a custom control that inherits from
    System.Web.UI.WebControls.CompositeControl. In the Property Grid in Design
    View, I only want the properties that I add in my code to be displayed in
    the Property Grid. Is there an attribute that will hide, by default, all
    inherited properties (except of course for some of the ones like ID that you
    always need, but I can use the <ComponentModel.Browsable(True) to fix that>
    attribute to fix that)? Also, I would like to point out that I would have
    preferred to use System.Web.UI.Control, but that did not seem to work since
    my custom control involves an ITemplate (using System.Web.UI.Control would
    at least have less properties to inherit). Any suggestions? Thanks.
    --
    Nathan Sokalski

    http://www.nathansokalski.com/
    Nathan Sokalski, Oct 14, 2009
    #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. Nathan Sokalski
    Replies:
    1
    Views:
    419
    Cor Ligthert
    Mar 17, 2009
  2. Garry McGlennon

    Persisting properties in property Grid (help!)

    Garry McGlennon, Jun 24, 2004, in forum: ASP .Net Web Controls
    Replies:
    0
    Views:
    127
    Garry McGlennon
    Jun 24, 2004
  3. Nathan Sokalski

    Control is not showing inherited properties in property grid

    Nathan Sokalski, Mar 15, 2009, in forum: ASP .Net Web Controls
    Replies:
    1
    Views:
    828
    Cor Ligthert
    Mar 17, 2009
  4. Replies:
    3
    Views:
    85
  5. 7stud --
    Replies:
    11
    Views:
    387
    7stud --
    Nov 9, 2007
Loading...

Share This Page