[英]WP7 How to add the style in C#
我在App.xaml(“ RoundButton”)中为按钮控件创建了样式。 我想用C#代码创建一个按钮,并将按钮的样式设置为App.xaml文件中创建的按钮。 是否有可能做到这一点?
Button btn = new Button();
btn.Style= (Style)App.Current.Resources["RoundButton"];
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.