Question about inheritance and designer behaviour


Author
Message
Greg McGuffey
Greg McGuffey
Strategic Support Team Member (4.8K reputation)
Group: Forum Members
Posts: 2K, Visits: 6.6K
I'm confused about how properties work within the designer.



If I have a form and I add a public property to the form, after I build the assembly, the property is there in the property window.



However, if I have a BO or a UserControl and I add a property, after I build the assembly, the property isn't in the property windows of the UserControl or BO itself. It will be in the property window of an instance I've dropped on a form or some other container, but not in the designer for the object itself. The property will also show up in the property window of any sub-classed objects.



So, what determines what ends up in that little property window?
Reply
Trent Taylor
Trent Taylor
StrataFrame Developer (14K reputation)StrataFrame Developer (14K reputation)StrataFrame Developer (14K reputation)StrataFrame Developer (14K reputation)StrataFrame Developer (14K reputation)StrataFrame Developer (14K reputation)StrataFrame Developer (14K reputation)StrataFrame Developer (14K reputation)StrataFrame Developer (14K reputation)
Group: StrataFrame Developers
Posts: 6.6K, Visits: 7K
What does your property definition look like? Do you have a ReflectionPropertyDescriptor (or any property descriptor) setup for these custom properties? If so then you may be fighting good ol' reflection and inheritance issues. There are times that you have to "re-expose" a property....however, it depends on how the properties are declared. I would need some more information to be able to give you any real suggestions.
GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...





Similar Topics

Reading This Topic

Login

Explore
Messages
Mentions
Search