<link rel="stylesheet" href="../css/style.css">
<div align="center">
  <p>
    <!--#include file="../SQLconn.asp"-->
    <%
    years=request("years")
    ftype=request("ftype")
    sendto=request("sendto")

%>
    <%
   
'检查系统有无 名单 
if sendto<>"" then
dim mysendto1
mysendto1=split(sendto,"|",-1,1)
for each sendtoinf in mysendto1
      set rscheck=server.createobject("adodb.recordset")
      rscheckSQL="select * from teachers where TName ='"&sendtoinf&"'" 
      rscheck.open rscheckSQL,conn,1,3
	  if  rscheck.eof and  rscheck.bof then
	      response.redirect   "FindError.asp?tname="&sendtoinf
	  end if 
next
end if
  
  
  
  
'标记文件给个人
set rssended=server.createobject("adodb.recordset")
rssendedsql="select * from wendangrenwu where (id is null)" 
rssended.open rssendedsql,conn,1,3

dim mysendto
mysendto=split(sendto,"|",-1,1)
for each sendtoinf in mysendto

    set Rscheck = Conn.Execute("select * from  wendangrenwu where  years='"&years& "' and  ftype='"&ftype& "' and  tname='"&sendtoinf& "'")
	if not Rscheck.eof and not Rscheck.bof then
	else
			rssended.addnew
			rssended("years")=years
			rssended("ftype")=ftype
			rssended("tname")=sendtoinf
			rssended.update
	end if 
	Rscheck.close
next


rssended.close
'response.redirect("RenWuList.asp target='teachername'")
'Response.Write("<script>top.location='RenWuList.asp'</script>")

'response.redirect   "RenWuList.asp?years="&years
%>
</p>
  <p align="center"><a href="RenWuList.asp?years=<%=years%>" target="_parent"></a></p>
  <p>&nbsp;</p>
  <p>&nbsp;</p>
  <p class="STYLETITLE2">任务添加成功！</p>
  <p>&nbsp;</p>
</div>
<p align="center"><a href="RenWuList.asp?years=<%=years%>" target="_parent" class="STYLETITLE">返回列表</a> </p>

