E
Evgeni Presmann
Hello all,
I've defined a custom control with the property of type string[].
If I assigned values to the property at design time, I can see these values
in the control as expected. However if I compiled the application, all the
values disappear.
Help please
Regards,
Evgeni
public class MediaElement : WebControl
{
private string[] parameters = null;
[DesignerSerializationVisibility(DesignerSerializationVisibility.Hidden)]
public string[] Parameters
{
get { return this.parameters; }
set { this.parameters = value; }
}
protected override void Render(HtmlTextWriter output)
{
if (this.parameters != null)
foreach (string parameter in this.parameters)
output.Write(parameter + " ");
else
output.Write( "empty list");
}
}
I've defined a custom control with the property of type string[].
If I assigned values to the property at design time, I can see these values
in the control as expected. However if I compiled the application, all the
values disappear.
Help please
Regards,
Evgeni
public class MediaElement : WebControl
{
private string[] parameters = null;
[DesignerSerializationVisibility(DesignerSerializationVisibility.Hidden)]
public string[] Parameters
{
get { return this.parameters; }
set { this.parameters = value; }
}
protected override void Render(HtmlTextWriter output)
{
if (this.parameters != null)
foreach (string parameter in this.parameters)
output.Write(parameter + " ");
else
output.Write( "empty list");
}
}