点击后如何更改按钮颜色? [英] How to change the button color after clik it?
本文介绍了点击后如何更改按钮颜色?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我想用c#在asp.net中单击按钮时更改按钮的颜色
谢谢!
i want to change back color of the button when i click it in asp.net with c#
Thank You!
推荐答案
在服务器端(通过执行回发,您可以像这样进行操作:
On server side (by doing the postback, you can go like this:
protected void Button1_Click(object sender, EventArgs e)
{
Button1.BackColor = Color.Yellow;
}
欢呼声
Cheers
protected void Button1_Click(object sender, EventArgs e)
{
Button1.BackColor = Color.Red;
}
使用简单的jquery
更改背景
Use simplejquery
to change the background
这篇关于点击后如何更改按钮颜色?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文