I'm creating a control with properties of type System.Net.IPAddress
. The designer shows these as read-only, and seems to be matching them up with resources. Is there a way to make it so that the user can edit these properties in the designer properties window, rather than having to open up the resource editor?
Asked
Active
Viewed 339 times
0

Simon
- 25,468
- 44
- 152
- 266
1 Answers
2
Found it - the answer is to fake it:
[Browsable(true)]
[DisplayName("IPAddress")]
public string IPAddressText
{
get { return this.IPAddress.ToString(); }
set { this.IPAddress = IPAddress.Parse(value); }
}
[Browsable(false)]
[DesignerSerializationVisibility(DesignerSerializationVisibility.Hidden)]
public IPAddress IPAddress
{
get;
set;
}

Simon
- 25,468
- 44
- 152
- 266