大家有没发现:在Page事件里判断哪个html Form被按下的功能?
问题如上!如果能判断出来,则不用执行多余的代码,提高性能! 问题点数:50、回复次数:4Top
1 楼windyyang(风萧萧)回复于 2003-09-02 16:08:59 得分 0
upTop
2 楼saucer(思归)回复于 2003-09-03 01:43:29 得分 50
哪个html Form被按下的???? if you mean button, try
if (Request.Form[Button1.UniqueID] != null)
{
//Button1 is clicked
}
else if (Request.Form[Button2.UniqueID] != null)
{
//Button2 is clicked
}
if your buttons are html submit buttons, use
if (Request.Form["SubmitButtonName"] != null)
{
//SubmitButtonNameis clicked
}
Top
3 楼windyyang(风萧萧)回复于 2003-09-03 09:33:35 得分 0
Thanks to Saucer!It's OK!And can you answer my at http://expert.csdn.net/Expert/topic/2204/2204694.xml?temp=.9314386Top
4 楼windyyang(风萧萧)回复于 2003-09-03 09:34:30 得分 0
Thanks to Saucer!It's OK!
And can you my answer at http://expert.csdn.net/Expert/topic/2204/2204694.xml?temp=.9314386Top



