K
Karen
Hi,
I would like to be able to select a text box on a form at runtime
and have a limited set of properties displayed using the .net property
grid. When the properties are updated the text box should be
automatically updated.
I have created a separate class (see code below) and set this as the
selected object when the text box is selected passing in the current
text. However when I update the properties window it doesn't update
the text box even with the RefreshProperties and NotifyParentProperty
attributes set.
Any ideas on this would be greatly appreciated
Karen
//Separate class
using System.ComponentModel;
public class TextBoxSettings
{
public TextBoxSettings(string Value)
{
Text = Value;
}
private string Text;
[CategoryAttribute("Global Settings"),
ReadOnlyAttribute(false),
RefreshProperties(RefreshProperties.All),
NotifyParentProperty(true)]
public string TextValue
{
get { return Text; }
set { Text = value;}
}
}
I would like to be able to select a text box on a form at runtime
and have a limited set of properties displayed using the .net property
grid. When the properties are updated the text box should be
automatically updated.
I have created a separate class (see code below) and set this as the
selected object when the text box is selected passing in the current
text. However when I update the properties window it doesn't update
the text box even with the RefreshProperties and NotifyParentProperty
attributes set.
Any ideas on this would be greatly appreciated
Karen
//Separate class
using System.ComponentModel;
public class TextBoxSettings
{
public TextBoxSettings(string Value)
{
Text = Value;
}
private string Text;
[CategoryAttribute("Global Settings"),
ReadOnlyAttribute(false),
RefreshProperties(RefreshProperties.All),
NotifyParentProperty(true)]
public string TextValue
{
get { return Text; }
set { Text = value;}
}
}