在WinForm里面的Leave就是LostFoucs,不知道在WebForm里面有没有,不过编写WebForm程序时,最好不要用这些事件,因为性能问题,它会加重网络的通信量

解决方案 »

  1.   

    <input name="txt2" onblur="txt2.value=parseInt(txt1.vaule)+parseInt(txt2.vaule)">
      

  2.   

    sorry:手误:<input id="txt1">
    <input id="txt2" onblur="txt3.value=parseInt(txt1.value)+parseInt(txt2.value)">
    <input id="txt3">
      

  3.   

    //在第三个控件获得焦点时触发:
    <script language="javascript">
    function GetMaxOfStudent()
    {
    var sMaxRow=Form1.txt1.value;
             var sMaxCol=Form1.txt2.value;
    if (sMaxRow>0 &&sMaxCol>0)
    {
        Form1.txt3.value=sMaxRow * sMaxCol;
    }
    }
    </script>
    <input id="txt1" runat="server" type="text" name="txt1">
    <input id="txt2" runat="server" type="text" name="txt2">
    <INPUT id="txt3" runat="server" type="text" name="txt3" onfocus="GetMaxOfStudent();">