日期:2014-05-18  浏览次数:20678 次

ControlTemplate只能有一个Line?
我在xaml中添加第2条线时提示:
The object 'ControlTemplate' already has a child and cannot add 'Line'. 'ControlTemplate' can accept only one 
child。
请大家帮忙看看,谢谢。

------解决方案--------------------
不是只能有一个Line而是只能有一个Child,你应该用一个容器来承载你的Line(s),比如Panel或者Grid