设为首页收藏本站Access中国

Office中国论坛/Access中国论坛

 找回密码
 注册

QQ登录

只需一步,快速开始

返回列表 发新帖
查看: 968|回复: 6
打印 上一主题 下一主题

[其它] 加密,解密问题?

[复制链接]
跳转到指定楼层
1#
发表于 2003-10-13 23:39:00 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式
现通过用ACCESS发送邮件到员工信箱,能不能对发送的报表内容进行加密,解密?


[此贴子已经被作者于2003-10-13 15:39:18编辑过]

分享到:  QQ好友和群QQ好友和群 QQ空间QQ空间 腾讯微博腾讯微博 腾讯朋友腾讯朋友
收藏收藏 分享分享 分享淘帖 订阅订阅
2#
 楼主| 发表于 2003-10-14 00:03:00 | 只看该作者
补充:即需要对*.snp内容进行加密,加密方式任意。

附:DoCmd.SendObject acReport, "ayslip_2003", "SnapshotFormat(*.snp)", EmailAddr, "", "", subject, body, False, "
3#
 楼主| 发表于 2003-10-14 00:36:00 | 只看该作者
GG们:帮忙看看吧,给点思路好吗?
4#
发表于 2003-10-14 00:45:00 | 只看该作者
用winrar/winzip打包 就可以加密了
5#
 楼主| 发表于 2003-10-14 00:49:00 | 只看该作者
我是想在下面代码中能够自动完成,通过代码能够实现吗?


源代码如下:
'------------------------------------------------------------
' sendmail
'------------------------------------------------------------
function sendmail(id as integer, username as string, emailaddr as string)
on error goto sendmail_err
    'dim id as integer
    dim cont as string 'condition for open report
    dim subject as string
    cont = "[id]=" & id
    subject = username & ",please find attached your pay slip for " & month(now())
    docmd.setwarnings false
    docmd.openreport "report_2003", acpreview, "", cont
    docmd.sendobject acreport, "report_2003", "snapshotformat(*.snp)", emailaddr, "", "", subject, "", false, ""
    docmd.close acreport, "report_2003"


sendmail_exit:
    exit function

sendmail_err:
    msgbox err.description
    resume sendmail_exit

end function


send 按钮单击事件代码
private sub send_click()
on error goto err_send_click
    dim db1 as dao.database
    dim user as dao.recordset
   
    set db1 = application.currentdb
    set user = db1.openrecordset("transfer", dbopentable)
   
    dim failuser as string
    failuser = "there some user's email is empty!  "
    with user
        do while not user.eof
            if isnull(![e-mail address]) then
                failuser = failuser & "      " & ![employee name]
            else
                sendmail ![id], ![employee name], ![e-mail address]
            end if
            .movenext
        loop
    end with
    msgbox failuser
exit_send_click:
    exit sub

err_send_click:
    msgbox err.description
    resume exit_send_click
end sub

高手帮帮忙吧!
6#
 楼主| 发表于 2003-10-14 00:54:00 | 只看该作者
我发送的只是ACCESS中的一个REPORT,也就是要发送给很多人不同的内容(根据表格相应内容自动变换),为了更简便、更高效地完成这个工作。
7#
 楼主| 发表于 2003-10-14 21:33:00 | 只看该作者
兄弟们:谁帮忙给看看吧,我现在一点思路都没有。
您需要登录后才可以回帖 登录 | 注册

本版积分规则

QQ|站长邮箱|小黑屋|手机版|Office中国/Access中国 ( 粤ICP备10043721号-1 )  

GMT+8, 2024-9-23 17:25 , Processed in 0.132513 second(s), 30 queries .

Powered by Discuz! X3.3

© 2001-2017 Comsenz Inc.

快速回复 返回顶部 返回列表