<!--#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
    if  trim(sendtoinf)<>"" then
    rssended.addnew
	rssended("years")=years
    rssended("ftype")=ftype
    rssended("tname")=sendtoinf
    rssended.update
	end if 
next
	

rssended.close
response.redirect   "modifyrenwu.asp?years="&years&"&ftype="&ftype
%>


