{"id":24979,"date":"2018-08-08T19:41:50","date_gmt":"2018-08-08T19:41:50","guid":{"rendered":"https:\/\/www.sperrysoftware.com\/Email-Tools\/?p=24979"},"modified":"2022-04-29T14:06:35","modified_gmt":"2022-04-29T14:06:35","slug":"creating-and-testing-rules-in-outlook","status":"publish","type":"post","link":"https:\/\/www.sperrysoftware.com\/Email-Tools\/creating-and-testing-rules-in-outlook\/","title":{"rendered":"Creating and Testing Rules in Outlook"},"content":{"rendered":"<p>Last time I wrote about the <a href=\"\/Email-Tools\/product\/timed-email-organizer\/\">Timed Email Organizer<\/a>, when the <a href=\"https:\/\/www.sperrysoftware.com\/Email-Tools\/new-features-added-to-timed-email-organizer\/\">new automatic reply and auto forward actions<\/a> were added. Shortly after the article was published, a customer called wanting to know how to create a rule that would move the email to a folder if the <b>To<\/b> field held a particular address. We filled out the rule together and then he remarked &#8220;<em>Ok, now I&#8217;ll just wait until an email arrives with that To address then look in the folder to make sure it&#8217;s working.<\/em>&#8221; I said &#8220;<em>Hold on, why don&#8217;t you just run the rule as a test?<\/em>&#8221; He didn\u2019t know what I was talking about and so I showed him how to create and test rules in Outlook \u2013 just like I\u2019ll show you now.<\/p>\n<h3>Create the Rule<\/h3>\n<p>When you create an Outlook rule in the Timed Email Organizer, wouldn\u2019t it be nice if you could test the rule to see which emails it would affect if it runs, but not actually run anything? That&#8217;s what the Test rules feature is all about. You simply select one or more rules from the main grid and click the Test button.<\/p>\n<p>In this example, I&#8217;ve been meaning to clean up my Inbox by deleting notification emails from our WordPress site. These notification emails let me know when a user has changed their password, or a new user has just registered on the site. They can be useful for a time, but after a while they build up in my Inbox and cause clutter so I want to automatically delete these emails after they are two weeks old. I&#8217;ve been meaning to do this for a while, so it&#8217;s a great time to get started.<\/p>\n<p>I start by clicking on the <strong>Add Rule<\/strong> button, then since this rule is going to be for the Inbox we select incoming emails. This brings me to the rule conditions window, where I add the <strong>If From Contains<\/strong> condition:<\/p>\n<figure id=\"attachment_25064\" aria-describedby=\"caption-attachment-25064\" style=\"width: 674px\" class=\"wp-caption aligncenter\"><a href=\"https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-content\/uploads\/2018\/08\/example-conditions.png\"><img fetchpriority=\"high\" class=\"wp-image-25064 size-full\" src=\"https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-content\/uploads\/2018\/08\/example-conditions.png\" alt=\"Rule conditions specify older than two weeks and from user &quot;Wordpress&quot;\" width=\"674\" height=\"937\" srcset=\"https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-content\/uploads\/2018\/08\/example-conditions.png 674w, https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-content\/uploads\/2018\/08\/example-conditions-510x709.png 510w, https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-content\/uploads\/2018\/08\/example-conditions-64x89.png 64w, https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-content\/uploads\/2018\/08\/example-conditions-216x300.png 216w\" sizes=\"(max-width: 674px) 100vw, 674px\" \/><\/a><figcaption id=\"caption-attachment-25064\" class=\"wp-caption-text\"><em>Rule conditions specify older than two weeks and from user &#8220;WordPress&#8221;<\/em><\/figcaption><\/figure>\n<p>Next, I navigate to the Actions tab, check the box to <strong>Delete the email<\/strong>:<\/p>\n<figure id=\"attachment_25065\" aria-describedby=\"caption-attachment-25065\" style=\"width: 674px\" class=\"wp-caption aligncenter\"><a href=\"https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-content\/uploads\/2018\/08\/example-actions.png\"><img class=\"size-full wp-image-25065\" src=\"https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-content\/uploads\/2018\/08\/example-actions.png\" alt=\"Delete action on a rule\" width=\"674\" height=\"937\" srcset=\"https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-content\/uploads\/2018\/08\/example-actions.png 674w, https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-content\/uploads\/2018\/08\/example-actions-510x709.png 510w, https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-content\/uploads\/2018\/08\/example-actions-64x89.png 64w, https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-content\/uploads\/2018\/08\/example-actions-216x300.png 216w\" sizes=\"(max-width: 674px) 100vw, 674px\" \/><\/a><figcaption id=\"caption-attachment-25065\" class=\"wp-caption-text\"><em>Delete these emails we no longer need them.<\/em><\/figcaption><\/figure>\n<p>I click Ok again, and I can see the rule in my grid:<\/p>\n<figure id=\"attachment_25066\" aria-describedby=\"caption-attachment-25066\" style=\"width: 1531px\" class=\"wp-caption aligncenter\"><a href=\"https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-content\/uploads\/2018\/08\/grid-of-rules.png\"><img class=\"size-full wp-image-25066\" src=\"https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-content\/uploads\/2018\/08\/grid-of-rules.png\" alt=\"Grid of rules image\" width=\"1531\" height=\"361\" srcset=\"https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-content\/uploads\/2018\/08\/grid-of-rules.png 1531w, https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-content\/uploads\/2018\/08\/grid-of-rules-510x120.png 510w, https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-content\/uploads\/2018\/08\/grid-of-rules-64x15.png 64w, https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-content\/uploads\/2018\/08\/grid-of-rules-300x71.png 300w, https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-content\/uploads\/2018\/08\/grid-of-rules-768x181.png 768w, https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-content\/uploads\/2018\/08\/grid-of-rules-1024x241.png 1024w, https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-content\/uploads\/2018\/08\/grid-of-rules-1080x255.png 1080w\" sizes=\"(max-width: 1531px) 100vw, 1531px\" \/><\/a><figcaption id=\"caption-attachment-25066\" class=\"wp-caption-text\"><em>Here&#8217;s the rule we want, already selected.<\/em><\/figcaption><\/figure>\n<h3>Test the Rule<\/h3>\n<p>And now for the magic &#8211; I want to test my new rule <em>without actually deleting anything<\/em>.<\/p>\n<figure id=\"attachment_25067\" aria-describedby=\"caption-attachment-25067\" style=\"width: 423px\" class=\"wp-caption aligncenter\"><a href=\"https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-content\/uploads\/2018\/08\/test-selected-rules.png\"><img loading=\"lazy\" class=\"size-full wp-image-25067\" src=\"https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-content\/uploads\/2018\/08\/test-selected-rules.png\" alt=\"test rules toolbar button image\" width=\"423\" height=\"221\" srcset=\"https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-content\/uploads\/2018\/08\/test-selected-rules.png 423w, https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-content\/uploads\/2018\/08\/test-selected-rules-64x33.png 64w, https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-content\/uploads\/2018\/08\/test-selected-rules-300x157.png 300w\" sizes=\"(max-width: 423px) 100vw, 423px\" \/><\/a><figcaption id=\"caption-attachment-25067\" class=\"wp-caption-text\">Closeup of Test button (highlighted).<\/figcaption><\/figure>\n<p>I next click the <strong>Test<\/strong> button and brought to a window where my emails will be shown &#8211; after I click the <strong>Run<\/strong> button. The add-in will run the selected rule against the Inbox (or whatever folder the rule is designed to operate in) and begins to fill in the grid with the emails that would be affected if this were not a test:<\/p>\n<figure id=\"attachment_25068\" aria-describedby=\"caption-attachment-25068\" style=\"width: 1018px\" class=\"wp-caption aligncenter\"><a href=\"https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-content\/uploads\/2018\/08\/run-rule-test.png\"><img loading=\"lazy\" class=\"size-full wp-image-25068\" src=\"https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-content\/uploads\/2018\/08\/run-rule-test.png\" alt=\"Rule test results image\" width=\"1018\" height=\"675\" srcset=\"https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-content\/uploads\/2018\/08\/run-rule-test.png 1018w, https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-content\/uploads\/2018\/08\/run-rule-test-510x338.png 510w, https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-content\/uploads\/2018\/08\/run-rule-test-64x42.png 64w, https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-content\/uploads\/2018\/08\/run-rule-test-300x199.png 300w, https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-content\/uploads\/2018\/08\/run-rule-test-768x509.png 768w\" sizes=\"(max-width: 1018px) 100vw, 1018px\" \/><\/a><figcaption id=\"caption-attachment-25068\" class=\"wp-caption-text\"><em>Results after running the test, showing me all the emails this rule will apply to.\u00a0 Notice the date column &#8211; all these emails are older than two weeks from the date of this blog post.<\/em><\/figcaption><\/figure>\n<p>Once the grid of emails is completely filled in, a button at the bottom of the grid becomes enabled. This button is labeled <strong>Execute Actions<\/strong> and it is appropriately named because it will run through each email in the Test grid and execute the actions based on the rule that put it there \u2026 moving emails to folders, marking with categories, etc. This is useful if the rule is configured properly and returning results that you expected to see. If not, you can just close this window, make adjustments to the rule, and then come back and test it again. In our case, I can quickly see that the From address always contains &#8220;WordPress&#8221; (and no others), and all emails are older than two weeks, so I click the <strong>Execute Actions<\/strong> button to get rid of them. The window refreshes and shows no emails left, so I know it&#8217;s complete.<\/p>\n<p>The <strong>Test<\/strong> functionality is a great way to see which emails will be affected by your rules, and the ability to execute rule actions is a great way to execute individual rules quickly.<\/p>\n<p>Read More: <a href=\"https:\/\/www.sperrysoftware.com\/Email-Tools\/how-to-deal-with-junk-mail\/\">How we use the Timed Email Organizer to help handle Junk Mail<\/a><\/p>\n<p>Now that you know how to check rules in Outlook, what rules are you most likely to test?<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Last time I wrote about the Timed Email Organizer, when the new automatic reply and auto forward actions were added&#8230;.<\/p>\n","protected":false},"author":1,"featured_media":25064,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[17,19],"tags":[50,80],"class_list":{"0":"post-24979","1":"post","2":"type-post","3":"status-publish","4":"format-standard","5":"has-post-thumbnail","7":"category-message","8":"category-tips","9":"tag-outlook-add-ins","10":"tag-timed-email-organizer"},"menu_order":0,"_links":{"self":[{"href":"https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-json\/wp\/v2\/posts\/24979","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-json\/wp\/v2\/comments?post=24979"}],"version-history":[{"count":0,"href":"https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-json\/wp\/v2\/posts\/24979\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-json\/wp\/v2\/media\/25064"}],"wp:attachment":[{"href":"https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-json\/wp\/v2\/media?parent=24979"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-json\/wp\/v2\/categories?post=24979"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.sperrysoftware.com\/Email-Tools\/wp-json\/wp\/v2\/tags?post=24979"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}