Dear team,
I would like to use tracking options for the mails I am sending through VBA code.
1. Request read receipt
2. Request delivery receipt
3. Using High importance option.
Can you help on this.
Using tracking options in outlook 2007
-
- StarLounger
- Posts: 81
- Joined: 21 Apr 2014, 10:45
- Location: Chennai, India
Using tracking options in outlook 2007
Regards,
Srinivasan
Srinivasan
-
- Administrator
- Posts: 78415
- Joined: 16 Jan 2010, 00:14
- Status: Microsoft MVP
- Location: Wageningen, The Netherlands
Re: Using tracking options in outlook 2007
To find out what you need, do the following:
- Start Outlook.
- Press Alt+F11 to activate the Visual Basic Editor (or click Visual Basic in the Code group on the Developer tab of the ribbon).
- Press F2 to activate the Object Browser (or select View | Object Browser).
- You already know from previous threads that the VBA name for a message is MailItem.
- Type MailItem in the search box and press Enter.
- Look through the list of members of MailItem for the features you need:
OriginatorDeliveryReportRequested can be used to request a delivery receipt. Boolean, i.e. True or False.
ReadReceiptRequested can be used to request a read receipt. Also Boolean.
Importance can be used to specify the importance of the message. You'll see that it is of type OlImportance. Click on OlImportance to see its possible values:
olImportanceHigh = 2
olImportanceLow = 0
olImportanceNormal = 1
You use a variable olMsg for the mail message. So you can use:
- Start Outlook.
- Press Alt+F11 to activate the Visual Basic Editor (or click Visual Basic in the Code group on the Developer tab of the ribbon).
- Press F2 to activate the Object Browser (or select View | Object Browser).
- You already know from previous threads that the VBA name for a message is MailItem.
- Type MailItem in the search box and press Enter.
- Look through the list of members of MailItem for the features you need:
OriginatorDeliveryReportRequested can be used to request a delivery receipt. Boolean, i.e. True or False.
ReadReceiptRequested can be used to request a read receipt. Also Boolean.
Importance can be used to specify the importance of the message. You'll see that it is of type OlImportance. Click on OlImportance to see its possible values:
olImportanceHigh = 2
olImportanceLow = 0
olImportanceNormal = 1
You use a variable olMsg for the mail message. So you can use:
Code: Select all
olMsg.OriginatorDeliveryReportRequested = True
olMsg.ReadReceiptRequested = True
olMsg.Importance = 2
You do not have the required permissions to view the files attached to this post.
Best wishes,
Hans
Hans
-
- StarLounger
- Posts: 81
- Joined: 21 Apr 2014, 10:45
- Location: Chennai, India