站内搜索
广告
在ASP中用EasyMailObject组件处理Exchange邮件源代码---读取邮件主题和大小(maillist1.asp)
作者:    来源:    点击:    日期:2007-3-30 23:34:39   
<%@ LANGUAGE="VBSCRIPT" %>
<%
'************************************************

'这个文件列出所有邮件,并把邮件内容显示窗口置为空白窗口
'作者:awayeah
'邮箱:awayeah@163.net

'************************************************
%>
<script language=vbscript>
parent.frmbottom.location.href="blank.htm"
sub cmdel_onClick()
'删除邮件
frmail.submit
end sub
</script>
<%
if session("straccount")="" or session("strpassword")="" then
Response.write("<html><title>错误,尚未登录</title><body><p align=center><br><br>你尚未登录,请先退出登录!<br><br>")
Response.Write ("<a href='login.asp' target='_top'><img src='http://www.wzsky.net/html/article/asp/asp2/logout.jpg' border=0></a></p></body></html>")
Response.End
end if
%>
<html>
<head>
<title>收邮件</title>
</head>
<STYLE>
<!--
A{text-decoration:none}
-->
</STYLE>
<body bgcolor="#008080" text="#000000">
<%
'定义邮件服务器地址
strserver=session("strserver")
'定义帐号
strAccount=session("straccount")
'定义密码
strPassword=session("strpassword")
'设置组件的各种属性
  Set POP3 = CreateObject("EasyMail.POP3.5")
   POP3.LicenseKey = "awa/S19I500R1AX30C0R3100"
   POP3.MailServer = strServer
   POP3.Account = strAccount
   POP3.Password = strPassword
   pop3.PreferredBodyFormat=1
   pop3.TimeOut=120

   x = POP3.Connect
   If x <> 0 Then
      Response.Write "<p align=center>连接错误: " + CStr(x) + "<br><br>请和管理员联系"
      POP3.Disconnect
      Response.End
   End If

   x = POP3.DownloadMessages(0)
   If x <> 0 Then
      Response.Write "下载错误: " + CStr(x) +"<br><br>请和管理员联系"
      POP3.Disconnect
      Response.End
   End If%>
<p><br></p>
首页 上一页 [1] [2] [3]  下一页 尾页 
在ASP中用EasyMailObject组件处理Exchange邮件源代码---读取邮件主题和大小(maillist1.asp) 评论