Custom Form Properties

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I am having an issue where I have added a custom property to one of my forms,
but it doesn't show up in the properties window in the designer window. The
property shows up in the intellisense in the code window. Any help is
appreciated.
 
Wade said:
I am having an issue where I have added a custom property to one of my
forms,
but it doesn't show up in the properties window in the designer window.
The
property shows up in the intellisense in the code window. Any help is
appreciated.

Make sure the 'Browsable' attribute is specified for the property. If this
doesn't solve your problem, post your code.
 
Wade said:
I am having an issue where I have added a custom property to one of
my forms, but it doesn't show up in the properties window in the
designer window. The property shows up in the intellisense in the
code window. Any help is appreciated.

It doesn't show because the designer creates and displays an instance of the
base class of the form, not an instance of your Form. It can't because you
are about to design your Form and the project might not have been compiled
yet. Consequently, the base class does not have your properties. The
designer shows, how your Form will "look like if it will be created later".

If you derived another Form from your Form, the property would be shown in
the property window if you open the derived Form in the designer.


Armin
 
Back
Top