how to change incoming mail conversationtopic successfully

Not open for further replies.


New Member
Outlook version
Email Account
Hi, I have following VBA codes which run properly for me most of time. However, I found a situation which cause the function doesn't work (the subject is not cut off the prefix "RE:" as supposed). When I am editing in Add Remind dialog, while an incoming mail is received in mailbox, the programme will fail.

My question is what is the reason, and what code should I add? I am grateful if somebody could kindly help me out, specially as I am nood in Outlook VBA.

'Cut off any standard prefix (like "RE:") of mail subject for any incoming mail
Private Sub Application_NewMailEx(ByVal EntryIDCollection As String)
Dim Utils, SPItem, varEntryIDs, NewSubJ, TempV

Dim i As Integer

Set Utils = CreateObject("Redemption.MAPIUtils")
Set SPItem = CreateObject("Redemption.SafePostItem")

varEntryIDs = Split(EntryIDCollection, ",")

For i = 0 To UBound(varEntryIDs)

Set SPItem.item = Application.Session.GetItemFromID(varEntryIDs(i))
NewSubJ = CutPrefix(SPItem.item.Subject)

TempV = Utils.HrSetOneProp(SPItem, &H70001F, NewSubJ, True) ' changes conversation
TempV = Utils.HrSetOneProp(SPItem, &H37001F, NewSubJ, True) ' changes subject


Set Utils = Nothing
Set SPItem = Nothing

End Sub

Outlook 2007 SP3
actually i found the Application_NewMailEx event not work properly every time. sometimes, it just won't run as reason unknown, I don't know if somebody has already experienced this problem with any certain reason. The situation I found was just one of the possible reason.

any idea?
Hi, except the reason still unknown for why programme not function during Reminder is setting, I found the reason for some mail items skipped from the Application_NewMailEx event might be:

For a POP3 account running under a very heavy load, it may skip a few items, but still is more reliable than Items.ItemAdd. If it is absolutely critical that you process all incoming items, it would be a good idea to supplement NewMailEx with a timer-based routine that checks periodically for unprocessed messages.


Anybody who has a complete solution, thanks to give advice.
Not open for further replies.
Similar threads
Thread starter Title Forum Replies Date
F How to change all incoming fonts to black? Using Outlook 3
M Use Macro to change account settings Outlook VBA and Custom Forms 0
D Unable to change AppointmentItem.Start property Outlook VBA and Custom Forms 4
sjmo2 Change subject for new e-mails only. Outlook VBA and Custom Forms 2
Horsepower Contact phone numbers randomly change Using Outlook 0
P Outlook 2016 Change Paste Special Default Format Using Outlook 8
whizzard Change FROM address based on TO or CC address Outlook VBA and Custom Forms 8
S Outlook 365 Can I change the possible range of highlighting colours when writing an Outlook email? Using Outlook 1
V Can one change the formatting of email title blocks? Using Outlook 0
S Unable to change Message Class Outlook VBA and Custom Forms 0
S New Outlook Appointment - Select All Body Text and Change Font and Size Outlook VBA and Custom Forms 1
J VBA Cannot programmatically input or change Value for User Defined field Using Outlook 1
C Outlook 365 Can you change the follow up colour? Using Outlook 1
A Change settings Send/receive VBA Outlook VBA and Custom Forms 0
E Outlook VBA change GetDefaultFolder dynamically Outlook VBA and Custom Forms 6
O What would be the recommended way to change an email address (family member)? Using Outlook 0
S Change "This Week" flag start date behavior Using Outlook 1
N Help creating a VBA macro with conditional formatting to change the font color of all external emails to red Outlook VBA and Custom Forms 5
D Change Microsoft Account password - what to do to update on all devices Using Outlook 4
S Outlook 2016 Change how Outlook shows me contacts in emails Using Outlook 0
Witzker HowTo Change message Class of contact form Outlook VBA and Custom Forms 0
Z Outlook 365 delete reminder you can’t make change to contents of this-read only folder Using Outlook 4
Witzker Pls help to change the code for inserting date in Ol contact body Outlook VBA and Custom Forms 5
R How to Change Margins In Google Docs...? Using Outlook 0
e_a_g_l_e_p_i Outlook 2010 How can I change the font size on right side appointment pane Using Outlook 12
diver864 vba for a rule to automatically accept meeting requests with 'vacation' in subject, change to all-day event, change to free, don't send reply Outlook VBA and Custom Forms 1
B Change Font and Font size using VBA Outlook VBA and Custom Forms 9
D Change senders title Using Outlook 1
W Recurrence: delete older occurrences / change earliest start time Outlook VBA and Custom Forms 0
E Change sending account depending on Subjectline Outlook VBA and Custom Forms 0
J Outlook 2013 Change color of text in data fields of contacts in Outlook 2013? Using Outlook 10
B Change row background color of selected item Using Outlook 1
PGSystemTester VBA To Change AppointmentItem.BusyStatus From MeetingItem Before Send Using Outlook 0
B Change from Address Outlook VBA and Custom Forms 0
X If you change expiration date of repeated task it dupplicates Using Outlook 1
E How to display "Change Folder" in Change Default Email Delivery Location in Exchange Outlook 2016 Using Outlook 1
Z See "Change View" Drop Down as a List? Using Outlook 1
V Change start time based on message duration Outlook VBA and Custom Forms 2
R Folder pane width change Using Outlook 90
S Change VBA script to send HTML email instead of text Outlook VBA and Custom Forms 3
S Outlook 2010 unable to change default font Using Outlook 7
P How can I change my calendar view back Using Outlook 3
A Edit subject - and change conversationTopic - using VBA and redemption Outlook VBA and Custom Forms 2
T Change the selected Message in the Outlook window Outlook VBA and Custom Forms 2
geofferyh How to change the Attachment File Name? Outlook VBA and Custom Forms 1
W Appointment occurrences change the location property Using Outlook 0
T Scheduled footer change Using Outlook 2
B Change font of reminder of an email header Outlook VBA and Custom Forms 3
CWM030 Name Change? Exchange Server Administration 9
V not able to change name in customize Ribbon Outlook VBA and Custom Forms 1

Similar threads