Author: Miroslav Stampar
URL: http://mstampar.awardspace.com/
If you write custom control’s like class LabelEx:Label, and override it’s Text property, then everytime you set Text property in Designer and compile the code, Visual Studio will clear content of Text property.
// If you write custom control's like class LabelEx:Label, and override
// its Text property, then everytime you set Text property in Designer
// and compile the code, Visual Studio will clear content of Text property.
// Solution:
[Browsable(true)]
[DesignerSerializationVisibility(DesignerSerializationVisibility.Visible)] //!!!
public override string Text {
get { return checkBox1.Text; }
set { checkBox1.Text = value; }
}










