VBA在Outlook里没有生效
我要在Outlook2007里面做一个宏,把“直接回复到发件人”改为一个特定的邮件地址。比如,我用ABC@163.com这个帐号发信,别人收到信后,点回复,默认的收件人不...
我要在Outlook2007里面做一个宏,把“直接回复到发件人”改为一个特定的邮件地址。比如,我用ABC@163.com这个帐号发信,别人收到信后,点回复,默认的收件人不是ABC@163.com,而是我设定的DEF@163.com。这个在Outlook里面默认是设置用哪个邮件地址发信,就回复到哪个地址,但我想改成一个恒定的地址,比如DEF@163.com.
参见网址:http://www.experts-exchange.com/Software/Office_Productivity/Groupware/Outlook/Q_23822179.html
我按照专家的说明做的:
1。把专家的代码复制进Outlook的VBA编辑器的 ThisOutlookSession 里面。
2。允许使用宏。
3。重启Outlook2007。
重启后,Outlook2007提示是否允许宏运行,点“是”,可是宏没有生效(在直接回复到×××邮件地址 这个字段,还是没有改过来。)
我看到跟贴的人说这个方法是成功的,为什么我的电脑就不成功呢?谁懂VBA,帮忙看下。
VBA代码如下:
Private Sub Application_ItemSend(ByVal Item As Object, Cancel As Boolean)
'Replace the address on the following line with the address replies should go to.'
Item.ReplyRecipients.Add "SomeAddress@company.com"
Item.ReplyRecipients.ResolveAll
Item.Save
End Sub
我的电脑环境:
主机Vista,虚拟机XP SP2。Outlook2007 在虚拟机XP上。杀毒软件为Zonealarm。
请问应该怎么办?
http://www.experts-exchange.com/Software/Office_Productivity/Groupware/Outlook/Q_23822179.html?sfQueryTermInfo=1+%22exchang+2007%22+2007+outlook
BlueDevilFan:Here's the code. Follow these instructions to use it.
1. Start Outlook
2. Click Tools->Macro->Visual Basic Editor.
3. If not already expanded, expand Microsoft Office Outlook Objects and click on ThisOutlookSession.
4. Copy the code and paste it into the right-hand pane of the VB Editor window.
5. Edit the code as necessary. I've placed comments where things need to change.
6. Click the diskette icon on the toolbar to save the changes.
7. Close the VB Editor.
8. Click Tools > Trust Center.
9. Select Macro Security.
10. Select either of the two bottom settings.
11. Close Outlook.
12. Start Outlook.
13. Outlook will display a dialog-box warning that ThisOutlookSession contains macros and asking if you want to allow them to run. Say yes.
Now, everything that's sent will have replies sent to the the addr 展开
参见网址:http://www.experts-exchange.com/Software/Office_Productivity/Groupware/Outlook/Q_23822179.html
我按照专家的说明做的:
1。把专家的代码复制进Outlook的VBA编辑器的 ThisOutlookSession 里面。
2。允许使用宏。
3。重启Outlook2007。
重启后,Outlook2007提示是否允许宏运行,点“是”,可是宏没有生效(在直接回复到×××邮件地址 这个字段,还是没有改过来。)
我看到跟贴的人说这个方法是成功的,为什么我的电脑就不成功呢?谁懂VBA,帮忙看下。
VBA代码如下:
Private Sub Application_ItemSend(ByVal Item As Object, Cancel As Boolean)
'Replace the address on the following line with the address replies should go to.'
Item.ReplyRecipients.Add "SomeAddress@company.com"
Item.ReplyRecipients.ResolveAll
Item.Save
End Sub
我的电脑环境:
主机Vista,虚拟机XP SP2。Outlook2007 在虚拟机XP上。杀毒软件为Zonealarm。
请问应该怎么办?
http://www.experts-exchange.com/Software/Office_Productivity/Groupware/Outlook/Q_23822179.html?sfQueryTermInfo=1+%22exchang+2007%22+2007+outlook
BlueDevilFan:Here's the code. Follow these instructions to use it.
1. Start Outlook
2. Click Tools->Macro->Visual Basic Editor.
3. If not already expanded, expand Microsoft Office Outlook Objects and click on ThisOutlookSession.
4. Copy the code and paste it into the right-hand pane of the VB Editor window.
5. Edit the code as necessary. I've placed comments where things need to change.
6. Click the diskette icon on the toolbar to save the changes.
7. Close the VB Editor.
8. Click Tools > Trust Center.
9. Select Macro Security.
10. Select either of the two bottom settings.
11. Close Outlook.
12. Start Outlook.
13. Outlook will display a dialog-box warning that ThisOutlookSession contains macros and asking if you want to allow them to run. Say yes.
Now, everything that's sent will have replies sent to the the addr 展开
2个回答
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询