Proper usage (best practices) of Browsable attribute in .NET for runtime grid component behavior
Posted
by Dan
on Stack Overflow
See other posts from Stack Overflow
or by Dan
Published on 2010-06-09T13:23:52Z
Indexed on
2010/06/09
13:42 UTC
Read the original article
Hit count: 424
I understand how Browsable attribute is supposed to work. It's supposed to hide a property from showing up in a PropertyGrid in design time.
It also has another effect in that it will stop a Property from showing up in components such as Grids, or specifically Infragistics WinGrid. I am not sure if it has this behaviour on regular Windows Forms grids.
This works, but it doesn't sound like Browsable is being use as intended when being used for 'Run time' displaying of a property on a grid component.
Any literature from Microsoft on proper use. Even though it works, I don't want to use this attribute to hide columns on a grid bound to a business object if it's not indeed the correct usage of the attribute, but rather something some grid vendors decided to use to determine property visibility on their grids.
© Stack Overflow or respective owner