PC Review
Forums
Newsgroups
Microsoft Outlook
Microsoft Outlook VBA Programming
Recognizing signed / encrypted messages OL2003
Forums
Newsgroups
Microsoft Outlook
Microsoft Outlook VBA Programming
Recognizing signed / encrypted messages OL2003
![]() |
Recognizing signed / encrypted messages OL2003 |
|
|
Thread Tools | Rate Thread |
|
|
#1 |
|
Guest
Posts: n/a
|
When I group my Inbox by Message Class, I see the expected results,
message classes such as "Message", "Out of Office Reply", "Message (StorageQuotaWarning)", "Meeting Cancellation". I can determine almost all of these programatically, by examining objMsg.Class and/or obj.MsgClass. However, messages of the type "SMIME Signed Messages" return the useless .MessageClass "IPM.Note" instead of "IPM.Note.SMIME", which is what I would expect. This causes my code all sorts of grief, since I can't tamper with this class of message (remove attachements and save). I cannot use a third party add-in, nor can I expect CDO to be available. At this point, I just need to be able to detect this kind of message. Is this possible in a pure VBA solution? I've seen others have had this issue too, but have not seen an usable answer (that I could follow at least.) I would be most appreciative of any help I can get with this. D. |
|
|
|
#2 |
|
Guest
Posts: n/a
|
You'll have to use the CdoPR_MESSAGE_CLASS property with CDO to access this
message class value. Try the sample below against an open e-mail item that's signed and note the value of objField: Sub GetMAPIMessageObjectFromActiveInspectorMailItem() Dim objItem As Object Dim objMessage As MAPI.Message Dim objSession As New MAPI.Session Dim objFields As MAPI.Fields, objField As MAPI.Field If ActiveInspector Is Nothing Then Exit Sub objSession.Logon , , , False Set objItem = ActiveInspector.CurrentItem Set objMessage = objSession.GetMessage(objItem.EntryID, objItem.Parent.StoreID) Set objFields = objMessage.Fields Set objField = objFields.Item(CdoPR_MESSAGE_CLASS) 'objField.Value = IPM.Note.SMIME.MultipartSigned objSession.Logoff Set objItem = Nothing Set objMessage = Nothing Set objField = Nothing Set objFields = Nothing End Sub -- Eric Legault - B.A, MCP, MCSD, Outlook MVP Try Picture Attachments Wizard for Outlook! http://tinyurl.com/ckytm Job: http://www.imaginets.com Blog: http://blogs.officezealot.com/legault/ "google@dcbarry.com" wrote: > When I group my Inbox by Message Class, I see the expected results, > message classes such as "Message", "Out of Office Reply", "Message > (StorageQuotaWarning)", "Meeting Cancellation". > > I can determine almost all of these programatically, by examining > objMsg.Class and/or obj.MsgClass. However, messages of the type "SMIME > Signed Messages" return the useless .MessageClass "IPM.Note" instead > of "IPM.Note.SMIME", which is what I would expect. > > This causes my code all sorts of grief, since I can't tamper with this > class of message (remove attachements and save). > > I cannot use a third party add-in, nor can I expect CDO to be > available. At this point, I just need to be able to detect this kind > of message. Is this possible in a pure VBA solution? > > I've seen others have had this issue too, but have not seen an usable > answer (that I could follow at least.) > > I would be most appreciative of any help I can get with this. > > D. > > |
|
|
|
#3 |
|
Guest
Posts: n/a
|
I don't think there is anything you can do: Outlook always tries to be
"nice" and returns a fake unencrypted message that looks just like a normal IPM.Note message. Extended MAPI/CDO 1.21/third party software to be able to open the message bypassing OOM is required. Dmitry Streblechenko (MVP) http://www.dimastr.com/ OutlookSpy - Outlook, CDO and MAPI Developer Tool <google@dcbarry.com> wrote in message news:1120142634.695029.211580@g49g2000cwa.googlegroups.com... > When I group my Inbox by Message Class, I see the expected results, > message classes such as "Message", "Out of Office Reply", "Message > (StorageQuotaWarning)", "Meeting Cancellation". > > I can determine almost all of these programatically, by examining > objMsg.Class and/or obj.MsgClass. However, messages of the type "SMIME > Signed Messages" return the useless .MessageClass "IPM.Note" instead > of "IPM.Note.SMIME", which is what I would expect. > > This causes my code all sorts of grief, since I can't tamper with this > class of message (remove attachements and save). > > I cannot use a third party add-in, nor can I expect CDO to be > available. At this point, I just need to be able to detect this kind > of message. Is this possible in a pure VBA solution? > > I've seen others have had this issue too, but have not seen an usable > answer (that I could follow at least.) > > I would be most appreciative of any help I can get with this. > > D. > |
|
![]() |
|
| Thread Tools | |
| Rate This Thread | |
|
|

Main Page 

