Consulting

Results 1 to 5 of 5

Thread: How to get the latest email from outlook based on subject and date?

  1. #1

    How to get the latest email from outlook based on subject and date?

    Hi

    Any idea on how to get the latest email of the same subject from outlook?
    Need to use vba to extract but i've no idea on how to go about doing it.
    Please help.

    Thanks alot

  2. #2
    VBAX Expert JP2112's Avatar
    Joined
    Oct 2008
    Location
    Astoria, NY
    Posts
    590
    Location
    Are you looking in the Inbox, or some other folder?
    Regards,
    JP

    Read the FAQ
    Getting free help on the web
    My website
    Please use [vba][/vba] tags when posting code

  3. #3
    either inbox or other folders also can because before i run the macro, i can choose to pick which folder i want it to search. right now i am able to get the latest email but if there are email replying in the same date but different time.
    the macro will pick out those 2 emails.

  4. #4
    VBAX Expert JP2112's Avatar
    Joined
    Oct 2008
    Location
    Astoria, NY
    Posts
    590
    Location
    Just so I understand correctly, you want to grab the previous email with the same subject as the most recent email. Is that correct?
    Regards,
    JP

    Read the FAQ
    Getting free help on the web
    My website
    Please use [vba][/vba] tags when posting code

  5. #5
    VBAX Newbie
    Joined
    May 2015
    Posts
    1
    Location
    Hello,

    Can I please bump this thread?

    I am using Outlook 2007 (*groan* I know...).

    I want to be able to take an email received to Folder X, and to find the most recent email already received with the same subject as the email just received... but when looking for an email with the same subject, I want to be able to look in the subfolders of Folder X.

    I will then make a script to assign to the new email the same category as the previous email, and move the new email to the same folder as the previous email.

    I found a script to find a parent email using ConversationIndex on the OutlookCode website (when I try to post a link my post gets rejected, unfortunately), but I have found ConversationIndex to be unreliable.

    I would prefer to just find any email previously received with the same ConversationTopic, and then to select the most recent of the emails returned.

    Can someone please assist? I would most greatly appreciate it!

    Thanks,

    Van

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •