Filter outlook 2010 Emails I sent-- but only to one recipient?

12

5

I want to search all the mails I sent to "zeev".

enter image description here

But I don't want to include mails which I've sent to "zeev" and "john"

e.g.:

enter image description here

So, I want to find emails which I've sent only to "zeev".

What is the phrase search word which I have to add?

Royi Namir

Posted 2013-06-30T09:06:33.760

Reputation: 4 568

Answers

6

I don't think it's possible to define your search criteria using Outlook's Advanced Find, however, an alternative way to accomplish your search is to create a custom view.
The custom view described below uses essentially the same SQL DASL query that I used in my other answer of creating a search folder via a macro. I believe the custom view will be easier to for you to implement.

To create the view:

  1. On the View tab, in the Current View group, click Change View, and then click Manage Views.
  2. Click New.
  3. In the Name of new view box, type a name for the view.
  4. In the Type of view box, select 'Table'.
  5. To change where the view is available, select an option under Can be used on, and then click OK.
  6. In the Advanced View Settings: New View dialog box, click Filter.
  7. Select the SQL tab and tick the 'Edit These Criteria Directly' checkbox.
  8. Paste the following DASL query into the textbox:
    "urn:schemas:httpmail:displayto" LIKE 'Zeev%' AND NOT "urn:schemas:httpmail:displayto" LIKE '%;%' AND "urn:schemas:httpmail:displaycc" =''
  9. When finished, click OK.
  10. To use the view immediately, click Apply View.
  11. To return to the standard view, on the View tab, in the Current View group, click Change View, and then click messages.

gm2

Posted 2013-06-30T09:06:33.760

Reputation: 756

This seemed very promising but unfortunately I can't get it to display any mail, not even after changing the SQL to "urn:schemas:httpmail:displayto" LIKE '%;%'. – Miserable Variable – 2014-07-22T15:39:29.687

Your SQL condition would match messages with more than one recipient in To: field. This query should match all messages in the location it's applied to: "urn:schemas:httpmail:displayto" LIKE '%' – gm2 – 2014-07-23T17:50:49.380

I haven't completely followed this but later I realized the other answer is also from you and that worked exactly like I wanted so I am a happy camper for now. – Miserable Variable – 2014-07-24T00:11:14.437

Great answer! I was trying to find out how to show messages that someone sent to ONLY me, and I did it with this query: "urn:schemas:httpmail:fromname" LIKE '%SenderName%' AND "urn:schemas:httpmail:displayto" LIKE '%MyName%' AND NOT "urn:schemas:httpmail:displayto" LIKE '%;%' AND "urn:schemas:httpmail:displaycc" ='' – pacoverflow – 2015-05-04T06:05:00.247

4

The following macro run once will create a Search Folder that persistently shows messages from Sent Items folder that were sent to only a single specified recipient.

In Outlook open the VBA editor using Alt+F11 and paste the code into the editor. Select a message you sent just to your buddy Zeev and then run the macro. You may need to set macro security to low to run the macro.

Sub CreateSearchFolderForOneRecipient()
On Error GoTo Err_CreateSearchFolderForOneRecipient

' Get the email address from a selected message
Dim oMail As Outlook.MailItem
Set oMail = ActiveExplorer.Selection.Item(1)
strSearchFolderName = "Msgs sent only to " & oMail.To

If oMail.To = "" Then
    Exit Sub
ElseIf InStr(1, oMail.To, ";") > 0 Then
    Err.Raise Number:=vbObjectError + 1000, _
        Description:="Selected message must have only 1 recipient in To: field"
End If

Dim strDASLFilter As String
' The trick to identifying messages sent to multiple recipients is the semi-colon ; delimiter.
' Semicolon can be searched using SQL DASL syntax but not in the Advanced Search form GUI
' Description of filter
' Line 1: Messages sent to specified recipient
' Line 2: 'To' field cannot contain semicolon
' LIne 3: 'CC' field must be empty
strDASLFilter = Chr(34) & "urn:schemas:httpmail:displayto" & Chr(34) & " = '" & oMail.To & "'" _
    & " AND NOT " & Chr(34) & "urn:schemas:httpmail:displayto" & Chr(34) & " LIKE '%;%'" _
    & " AND " & Chr(34) & "urn:schemas:httpmail:displaycc" & Chr(34) & " = ''"

Dim strScope As String
strScope = "'Sent Items'"

Dim objSearch As Search
Set objSearch = Application.AdvancedSearch(Scope:=strScope, Filter:=strDASLFilter, _
    SearchSubFolders:=True, Tag:="SearchFolder")

' Save the search results to a searchfolder
objSearch.Save (strSearchFolderName)

Set objSearch = Nothing

Exit Sub


Err_CreateSearchFolderForOneRecipient:
    MsgBox "Error # " & Err.Number & " : " & Error(Err)

End Sub

Macro is a modified version of code from How to create an Outlook search folder using VBA

gm2

Posted 2013-06-30T09:06:33.760

Reputation: 756

iv created the macro but how do i run it ? i selected a mail and then i do what ? – Royi Namir – 2013-07-25T07:14:49.287

After you select a message go back to the code editor window, click once anywhere in the code block, then click the run/play button on toolbar. – gm2 – 2013-07-25T15:33:55.547

0

It's pretty easy. Select 'Sent' on the left pain. Above the list of emails click the drop-down and select "By: To" to reorder by recipient. Scroll down and find the set of emails just 'To' the required recipient. Click the bar to show the emails. You can now select the emails you need holding down shift or command then File > Print > PDF for example.

Adey Jade

Posted 2013-06-30T09:06:33.760

Reputation: 1

0

You will have to use the Advanced Find option (CTRL+SHIFT+F) in the sent to put 'zeev'

Then you need to go in the advanced tab on the right where you will need to define another criteria:

The field would be To

The conditioner will be Doesn't Contain

The value will be 'john'

Note the quotes around the names as it will make the difference.

Now when you hit search you will now see all emails sent to only Zeev

Ash King

Posted 2013-06-30T09:06:33.760

Reputation: 1 175

1what about if i sent also to paul ? I cant remember all the recipients .... – Royi Namir – 2013-07-24T13:24:24.293

As far as I am aware, I don't think you can make it where you search for only that one person when nobody else is added in. It may be a case of doing a search finding another one to exclude, add that into the search until you're left with only zeev in the sent to box. – Ash King – 2013-07-24T13:54:21.380

-1

from:"Your Name" to:"Zeev" AND NOT to:"john"

The link below is a reference to instant search terms and operators:

http://office.microsoft.com/en-gb/outlook-help/learn-to-narrow-your-search-criteria-for-better-searches-in-outlook-HA010238831.aspx

john

Posted 2013-06-30T09:06:33.760

Reputation: 488

what about if i sent also to paul ? I cant remember all the recipients .... – – Royi Namir – 2013-07-24T13:46:10.477

Ah, you mean exclusively. Hmm... Let me think. – john – 2013-07-24T13:46:39.720

@john - Just use a wild card character. – Ramhound – 2013-07-24T20:29:51.047

@Ramhound tried that. It didn't work, you got an example to update the answer with? – john – 2013-07-24T20:43:27.480

-2

Just follow the following instructions to complete your job...
1. Open Outlook 2010.
2. Click on 'Sent Items' at left side panel.
3. Click on Search box in the middle panel. Result: You will see the ribbon tool bar changed to 'Search'.
4. Click on 'More'(+ icon in Green colour).
5. Select 'To' from the list.
6.Enter the mail ID in 'To' field to search what are the mails you have sent to a particular person.

I could not add an image due to my reputation score crisis. Sorry for that!!

hanuman411

Posted 2013-06-30T09:06:33.760

Reputation: 9

nope... it dos not work cuz it shows other recipients as well...http://i.stack.imgur.com/v76MY.jpg

– Royi Namir – 2013-07-25T06:49:33.293

Are you sure you are entering the mail id in newly added 'To' field.Note: If you have sent a mail to more than one recipient those mails also will be listed in result because search criteria met for 'To' field. – hanuman411 – 2013-07-25T07:03:52.840

2Are you expecting me to remember the mail ID ? i need to find for exclusive recipient and not by mail Id. – Royi Namir – 2013-07-25T07:05:03.567

No need to remember the mail id. you can just start typing the name also will work. – hanuman411 – 2013-07-25T07:10:08.273

start typing the name and then..... ? this is the same result as my pic – Royi Namir – 2013-07-25T07:13:30.423

For Ex: If in my company my colleague name is unique and when i start typing his name like "Charlie" then Outlook will populate the results dynamically before completing the search. – hanuman411 – 2013-07-25T07:17:27.493

2But he will provide other recpient as well. am i that unclear ? did you read my question ? for example if i sent to john and paul and im looking only for john : it will give me the email which i sent to paul and john also. and i dont want that. – Royi Namir – 2013-07-25T07:18:36.050