//如通过object 使用button控件(利用object as button): public static void fun(object sender) { (sender as Button).BackColor = System.Drawing.Color.Green; }