{"id":744,"date":"2017-06-12T20:40:43","date_gmt":"2017-06-12T20:40:43","guid":{"rendered":"http:\/\/us111.siteground.us\/~tlhouse0\/ptfbpro.com\/automate\/?p=744"},"modified":"2017-06-12T20:41:49","modified_gmt":"2017-06-12T20:41:49","slug":"how-to-play-an-alert-sound-when-a-window-appears-or-changes-state","status":"publish","type":"post","link":"https:\/\/ptfbpro.com\/automate\/how-to-play-an-alert-sound-when-a-window-appears-or-changes-state\/","title":{"rendered":"How to play an alert sound when a window appears (or changes state)"},"content":{"rendered":"<p>Recently a couple of people asked me how to set up PTFB Pro to play a sound when a certain window pops up. This is actually a really easy thing to do &#8211; just follow these basic steps:<\/p>\n<p>1. Open up PTFB Pro&#8217;s main window and choose to create a &#8220;New Window Macro&#8221; for the target window<\/p>\n<p><a href=\"http:\/\/us111.siteground.us\/~tlhouse0\/ptfbpro.com\/automate\/wp-content\/uploads\/2017\/06\/NewWindowMacro.png\"><img loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-745 alignleft\" src=\"http:\/\/us111.siteground.us\/~tlhouse0\/ptfbpro.com\/automate\/wp-content\/uploads\/2017\/06\/NewWindowMacro.png\" alt=\"\" width=\"510\" height=\"182\" srcset=\"https:\/\/ptfbpro.com\/automate\/wp-content\/uploads\/2017\/06\/NewWindowMacro.png 510w, https:\/\/ptfbpro.com\/automate\/wp-content\/uploads\/2017\/06\/NewWindowMacro-300x107.png 300w\" sizes=\"(max-width: 510px) 100vw, 510px\" \/><\/a><\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>2. Stop recording immediately to produce an empty &#8211; or virtually empty &#8211; macro (tapping the Pause\/Break key on your keyboard is the quickest way to do this)<\/p>\n<p>3. Double-click your new macro to open it up for editing, and switch to the &#8220;Notifications&#8221; page. The bottom section causes a sound to play when the macro runs automatically. You can pick one of the predefined Windows sounds, or supply the path to a &#8220;.wav&#8221; file of your own choosing.<\/p>\n<p><a href=\"http:\/\/us111.siteground.us\/~tlhouse0\/ptfbpro.com\/automate\/wp-content\/uploads\/2017\/06\/SoundNotification.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignleft size-medium wp-image-747\" src=\"http:\/\/us111.siteground.us\/~tlhouse0\/ptfbpro.com\/automate\/wp-content\/uploads\/2017\/06\/SoundNotification-300x282.png\" alt=\"\" width=\"300\" height=\"282\" srcset=\"https:\/\/ptfbpro.com\/automate\/wp-content\/uploads\/2017\/06\/SoundNotification-300x282.png 300w, https:\/\/ptfbpro.com\/automate\/wp-content\/uploads\/2017\/06\/SoundNotification.png 570w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a><\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>And that&#8217;s all there is to it. If needed you can further refine your macro so that it only fires when the window enters a particular state, e.g. when the title changes to a certain pattern (configure this in the &#8220;Identifying the Target&#8221; page), or when part of the window conetnts changes visually (use the new &#8220;Visual Change&#8221; option on the &#8220;Triggers&#8221; page for this).<\/p>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Recently a couple of people asked me how to set up PTFB Pro to play a sound when a certain window pops up. This is actually a really easy thing <a class=\"more-link\" href=\"https:\/\/ptfbpro.com\/automate\/how-to-play-an-alert-sound-when-a-window-appears-or-changes-state\/\">Continue Reading &rarr;<\/a><\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"footnotes":""},"categories":[25,19],"tags":[],"class_list":["post-744","post","type-post","status-publish","format-standard","hentry","category-news","category-run-a-macro-or-script-every-time-a-window-opens"],"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/ptfbpro.com\/automate\/wp-json\/wp\/v2\/posts\/744"}],"collection":[{"href":"https:\/\/ptfbpro.com\/automate\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/ptfbpro.com\/automate\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/ptfbpro.com\/automate\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/ptfbpro.com\/automate\/wp-json\/wp\/v2\/comments?post=744"}],"version-history":[{"count":0,"href":"https:\/\/ptfbpro.com\/automate\/wp-json\/wp\/v2\/posts\/744\/revisions"}],"wp:attachment":[{"href":"https:\/\/ptfbpro.com\/automate\/wp-json\/wp\/v2\/media?parent=744"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/ptfbpro.com\/automate\/wp-json\/wp\/v2\/categories?post=744"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/ptfbpro.com\/automate\/wp-json\/wp\/v2\/tags?post=744"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}