Properties collection

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Luc Trépanier

    #1

    Properties collection

    How can I know if an object has a particular property.
    For example, if I create a new user control for a textbox
    and I add a new property called "NewPropery ", I want to be
    able to find if the textbox on the form has this knew
    property. Is there a way I can loop in a property
    collection.

    Thanks.

    Luc.
  • Jon Skeet [C# MVP]

    #2
    Re: Properties collection

    Luc Trépanier <luc.trepanier@ etsmtl.ca> wrote:[color=blue]
    > How can I know if an object has a particular property. [/color]

    Have a look at Type.GetPropert y.

    --
    Jon Skeet - <skeet@pobox.co m>
    Pobox has been discontinued as a separate service, and all existing customers moved to the Fastmail platform.

    If replying to the group, please do not mail me too

    Comment

    Working...