"John Saunders" <(E-Mail Removed)> 在郵件
news:(E-Mail Removed) 中撰寫...
> "Franz" <(E-Mail Removed)> wrote in message
> news:(E-Mail Removed)...
> > solved
> > thanks anyway :-)
> >
> > "Franz" <(E-Mail Removed)> 在郵件
> > news:%23NqV$(E-Mail Removed) 中撰寫...
> > > UserControl has overrided the Text property. I can't view it in the
> > > designer. I subclass it and set the Browsable attribute to true. I can
> see
> > > the Text property now. Although the text becomes bold everytime I
> modified
> > > it, no code is added to InitializeComponent. What is the problem? Why
no
> > > code is generated? What kind of attribute do I need to add?
> > > (I have also added
> > > [Designer("System.Windows.Forms.Design.ParentControlDesigner,
> > > System.Design", typeof(IDesigner))] at the beginning of the subclass
of
> > > UserControl.)
> > >
>
>
> What was the solution?
Sorry, I forget to post out the solution.
[Browsable(true), DefaultValue(""),
DesignerSerializationVisibility(DesignerSerializationVisibility.Visible)]
public new string Text {
get { return base.Text; }
set {
base.Text = value;
Foo();
}
}
|