I had this code working when i was on Windows 8.1 and i upgraded to Windows 10 and now it isnt working.
I made my own Archieve and had all mail move a copy to it when it comes in to my Inbox. This code used to mark the mail in my Inbox as unread after the copy.
Please check it out.
to mark the mail in my Inbox as unread after the copy.
the code appears to be the opposite to this, marks all as read
does the code run on application startup? does the code run when items are added to the collection?
put a stop statement (or messagebox) to see it they are actually running
i do my best to test code works before i post it, but sometimes am unable to do so for some reason, and usually say so if this is the case. Note code snippets posted are just that and do not include error handling that is required in real world applications, but avoid On Error Resume Next
dim all variables as required as often i have done so elsewhere in my code but only posted the relevant part
come back and mark your original post as resolved if your problem is fixed
pete
the code appears to be the opposite to this, marks all as read
does the code run on application startup? does the code run when items are added to the collection?
put a stop statement (or messagebox) to see it they are actually running
How it reads online where i got the code is
Code:
Private Sub Items_ItemAdd(ByVal Item As Object)
Item.UnRead = False
Item.Save
End Sub
I changed it back to this and nothing changes.
As you can see from this picture. I want a copy of my mail to be moved to Archived Folder and for the Inbox to remain unread and Archived to be read.
i do my best to test code works before i post it, but sometimes am unable to do so for some reason, and usually say so if this is the case. Note code snippets posted are just that and do not include error handling that is required in real world applications, but avoid On Error Resume Next
dim all variables as required as often i have done so elsewhere in my code but only posted the relevant part
come back and mark your original post as resolved if your problem is fixed
pete