自定义控件的样式问题
我自己做了一个自定义控件,其中要对部分内容设定样式
添加一个属性
public Style TITLEStyle
{
get{
if( titleStyle != null )
return titleStyle;
else
return new Style();
}
set{ titleStyle = value; }
}
在CreateChildCont()
{
//我这么用得
TableCell c = new TableCell();
if( titleStyle != null )
c.ApplyStyle( titleStyle );
}
结果在测试页面上我设定了 TitleStyle 的任何子选项 CssClass , BackColor , vs.net 就停止响应
why?????