No, both codes scan the whole folder content, no matter if they are unread, read, or both. While I use "Sort unread before read" option set ON on most of my folders, toggling it OFF didn't change the code behavior. I tested all scenarios I could think of including unread messages with some read in between.
It might be something related to the folder's index as longer code exits immediately if all of the folder's messages are marked read. If the shorter code is used, no matter if all, some or none messages are marked unread it will take much more time to complete.
<p>No, both codes scan the whole folder content, no matter if they are unread, read, or both. While I use "Sort unread before read" option set ON on most of my folders, toggling it OFF didn't change the code behavior. I tested all scenarios I could think of including unread messages with some read in between.</p><p>
It might be something related to the folder's index as longer code exits immediately if all of the folder's messages are marked read. If the shorter code is used, no matter if all, some or none messages are marked unread it will take much more time to complete.
</p>
-- Euler
Pegasus Mail 4.81.1154 Windows 7 Ultimate
IERenderer: 2.7.1.5 AttachMenu: 1.0.1.2
PMDebug: 2.5.8.34 BearHTML 4.9.9.6