locked
Customizing data view in Properties Windows RRS feed

  • Question

  • Hi,
    i have a custom editor and it displays selected object properties in VS Properties Windows . The data for properties windows are provided using ITrackSelection and data objects set in ISelectionContainer . The data object i a POCO with exposed set of properties, which are then displayed in properties windows. So far so good.
    However, the Object Selection combo (above Properties Window) shows ugly full implementing class name. The documentation about Properties Window mentions several interfaces to implement to customize properties view. One of them is IProvideClassInfo   that should allow customizing info in the Object Selection combo.
    I've tried implement its only method on the POCO class and it's not called (also Properties Window doc says that this interface has Name property, but it doesn't). I've tried to annotate the POCO class with Guid and ComVisible attributes and expose Name property annotated with DispId(800) - I've read somewhere that Disp ID 800 is used for Name. But still nothing.
    The same problem is in providing info (e.g. documentation) about properties. According to the doc this should be possible via IVsPerPropertyBrowsing inteface. But again, implementing this on the data class doesn't work, methods are not called. Neither on my WindowPane . (Providing doc data for properties using annotation attributes works ok)
    Question 1 ) On which class(es) should be implemented all those Properties Window related interface?
    Question 2 ) Is that a better way how to provide data?

    Thanks,
    Vlastimil Hajek
    Tuesday, February 23, 2010 1:42 PM