你这个控件应该有一个name属性,如name=mybtn;在后台需要更改边框和背景的事件中,mybtn.background=newsoildbrush(colors.white);//改成白色背景mybtn.borderbrush=newsoildbrush(colors.black);//黑色边框...等等其他的属性,。