<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Exame_Fensu_keyin.aspx.cs" Inherits="RPWEB.Manage.Exame_Fensu_keyin" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head id="Head1" runat="server">
    <title></title>
    <link href="../Web_CSS/WebCss.css" rel="stylesheet" type="text/css" />
    <script type="text/javascript" src="../JS/Jquery.js"></script>
    <script type="text/javascript" src="../JS/ManageWeb.js"></script>
     <script language="javascript" type="text/javascript">     
          //chooseOne()函式，參數為觸發該函式的元素本身      
     function chooseOne(cb){ ///只选择一项     
         //先取得同name的chekcBox的集合物件      
         var obj = document.getElementsByName("CheckMes");      
         for (i=0; i<obj.length; i++){      
             //判斷obj集合中的i元素是否為cb，若否則表示未被點選      
             if (obj[i]!=cb) obj[i].checked = false;      
             //若是 但原先未被勾選 則變成勾選；反之 則變為未勾選      
             //else  obj[i].checked = cb.checked;      
             //若要至少勾選一個的話，則把上面那行else拿掉，換用下面那行      
             else obj[i].checked = true;      
         }      
     } 
     
     
function document.onkeydown() //网页内按下回车触发   
{   
//alert(event.keyCode);
if(event.keyCode==13 || event.keyCode==40)  //回车键改为TAB键 
{   
//document.getElementById("Button1").click();    
//return false; 
window.event.keyCode   =   9;   
   
}   
} 
     
     </script> 
     





     
<script language="javascript">
<!--
//function getValue(_obj){
// var caiying2007=_obj.parentNode.parentNode.getElementsByTagName("td")[0].innerHTML
// caiying2007=parseInt(caiying2007.split("(")[1])
// return caiying2007
//}
function checkValue(_obj){
//alert(_obj.name);
    if(isNaN(_obj.value)){
        alert("必须是数字");
        _obj.value=_obj.value.substr(0,_obj.value.length-1)
        _obj.focus()
        return false;
    }
    var defValue=150;//getValue(_obj)
    if(_obj.value>defValue && _obj.name=="fen"){
        alert("数值过大！\n\n最高分是："+defValue+" 分");
        _obj.value=_obj.value.substr(0,_obj.value.length-1)
//        _obj.value=""
        _obj.focus()
    }
}
onload=function init(){
 var obj=document.getElementById("form1").getElementsByTagName("input"),j=obj.length
 for (var i=0;i<j-1;i++)
  obj[i].onkeyup=function(){checkValue(this)}
}
//-->
</script>
       
    
</head>
<body>









    <form id="form1" runat="server">
       <div class="div_All">
        <div class="Body_Title">
            <a href=exame_manage.aspx>考试管理</a> >><%=getExameName(htm_exame_id)%>成绩导入</div>
            <asp:Label ID="Exameidtemp" runat="server" Text="Label" Visible="False"></asp:Label>
            <asp:Label ID="Subject_idLabel" runat="server" Text="Label" Visible="False"></asp:Label>
            <asp:Label ID="SubjectLabel" runat="server" Text="Label" Visible="False"></asp:Label>
            
                           <table cellpadding="3" cellspacing="1" class="Admin_Table">


                <tr>

                <td>   


                               
                    选择科目：
        <asp:Repeater ID="RpPowerUser" runat="server" 
           >
            <HeaderTemplate>

            </HeaderTemplate>
            <ItemTemplate>
            <%--<input type="radio" value='<%#Eval("Subject_id")%>'  name="CheckMes" />--%>
            <%#Subjectcheckedradio(Convert.ToInt32(Eval("Subject_id").ToString()), Eval("SubjectName").ToString())%>
<%#SubjectFont(Convert.ToInt32(Eval("Subject_id").ToString()), Eval("SubjectName").ToString())%>




            </ItemTemplate>
        </asp:Repeater>
<asp:HiddenField ID="HSelectID" runat="server" Value="" />                   
                               
                                考号从<asp:TextBox ID="TextBox1" runat="server" Width="52px"></asp:TextBox>
                                到<asp:TextBox ID="TextBox2" runat="server" Width="60px"></asp:TextBox>
                                <asp:Button ID="BtnAllAction1" runat="server" Text="选择" 
                        onclick="Button1_Click" />


                
            
                                </td></tr>
                </table>
                
                
                
                

            <asp:Repeater ID="Repeater2" runat="server" 
            >
            <HeaderTemplate>
                <table cellpadding="3" cellspacing="1" class="Admin_Table2">
                    <thead>
                        <tr class="Admin_Table_Title">
                            <th >
                                 所在班级
                            </th>
                            
                            <th >
                                 学生姓名
                            </th> 
                            <th >
                                 学生学号
                            </th> 
                                                        
                            <th >
                                 学生考号
                            </th> 
                                                        
                                                       
                            <th>
                               <%=SubjectLabel.Text%>
                            </th>
                        </tr>
                    </thead>
            </HeaderTemplate>
            <ItemTemplate>
                <tr>

                    <td>
                   <%#Eval("ClassNUM")%>
                   （<%#GetClassNameByEIDClassNUM(Convert.ToInt32(Eval("exam_id").ToString()), Eval("ClassNUM").ToString())%>）
                    </td>
                   <td>
                   
                        <%#Eval("StudentName")%>
                   
                    </td>  
                    <td>
                        <%#Eval("StudentNUM")%>
                    </td>
                   <td>
 <%#Eval("ExameNUM")%>
                    </td>  
                    

                                      
                <td>
                    <%#GetFensuTextBox(Convert.ToInt32(Eval("exam_id").ToString()), Eval("StudentNUM").ToString(), Convert.ToInt32(Subject_idLabel.Text))%>
                    </td>                </tr>
            </ItemTemplate>
            <FooterTemplate>
                </table></FooterTemplate>
        </asp:Repeater>
    
                <div class="BottomPage">
<asp:HiddenField ID="fens" runat="server" Value="" />
<asp:HiddenField ID="StudentNUMs" runat="server" Value="" />
<asp:Button ID="Fensukeyin" runat="server" Text="录入分数" onclick="Button1_Click1" Visible="False" />
                   </div>
    
    
    </div>
    </form>
</body>
</html>
