日期:2014-05-16 浏览次数:21018 次
sendto=request("TO_NAME")
dim mysendto
mysendto=split(sendto,",",-1,1)
for i=0 to ubound(mysendto)
set conn=opendb("oabusy","conn","accessdsn")
set rs=server.createobject("ADODB.recordset")
sql = "select * from senddate"
rs.Open sql,conn,1,3
rs.addnew
rs("title")=title
Rs("documenttype")=documenttype
Rs("content")=content
rs("sender")=oabusyusername
rs("recipientusername")=mysendto(i)
rs("recipientuserdept")=recipientuserdept
rs("inputdate")=date
rs("filename")=linkpath
rs.update
Response.Write(""&mysendto(i)&"")
next
rs.close
conn.close
set rs=nothing
set conn=nothing
sendto=request("TO_NAME")
dim mysendto
mysendto=split(sendto,",",-1,1)
set conn=opendb("oabusy","conn","accessdsn")
set rs=server.createobject("ADODB.recordset")
sql = "select * from senddate"
rs.Open sql,conn,1,3
'这些代码放外面来
for i=0 to ubound(mysendto)
if mysendto(i)<>"" then''''''''加是否为空的判断就好了
rs.addnew
rs("title")=title
Rs("documenttype")=documenttype
Rs("content")=content
rs("sender")=oabusyusername
rs("recipientusername")=mysendto(i)
rs("recipientuserdept")=recipientuserdept
rs("inputdate")=date
rs("filename")=linkpath
rs.update
Response.Write(""&mysendto(i)&"")
end if
next
rs.close
conn.close
set rs=nothing
set conn=nothing