{"id":55293,"date":"2008-06-24T02:17:00","date_gmt":"2008-06-24T02:17:00","guid":{"rendered":"https:\/\/blogs.technet.microsoft.com\/heyscriptingguy\/2008\/06\/24\/hey-scripting-guy-how-can-i-open-and-close-outlook-attachments\/"},"modified":"2008-06-24T02:17:00","modified_gmt":"2008-06-24T02:17:00","slug":"hey-scripting-guy-how-can-i-open-and-close-outlook-attachments","status":"publish","type":"post","link":"https:\/\/devblogs.microsoft.com\/scripting\/hey-scripting-guy-how-can-i-open-and-close-outlook-attachments\/","title":{"rendered":"Hey, Scripting Guy! How Can I Open and Close Outlook Attachments?"},"content":{"rendered":"<p><img decoding=\"async\" height=\"34\" width=\"34\" src=\"https:\/\/devblogs.microsoft.com\/wp-content\/uploads\/sites\/29\/2019\/02\/q-for-powertip.jpg\" align=\"left\" alt=\"Hey, Scripting Guy! Question\" border=\"0\" title=\"Hey, Scripting Guy! Question\" class=\"nearGraphic\" \/><\/p>\n<p>Hey, Scripting Guy! We recently implemented a scheme whereby Team Leads or Contract Sponsors may request server access for their Team members by submitting an Excel spreadsheet. To this end, I proposed a script that will open Outlook, look for items in the Inbox that contain a particular Subject line (we will pick the wording later) and, for each item in the collection, open the attached spreadsheet, copy the data to another spreadsheet, and then close the attachment. I have successfully completed all the steps except opening the attachment. Can you help me with that?<\/p>\n<p>&#8212; FS<\/p>\n<p><img decoding=\"async\" height=\"5\" width=\"5\" src=\"https:\/\/devblogs.microsoft.com\/scripting\/wp-content\/uploads\/sites\/29\/2019\/05\/spacer.gif\" alt=\"Spacer\" border=\"0\" \/><img decoding=\"async\" height=\"34\" width=\"34\" src=\"https:\/\/devblogs.microsoft.com\/wp-content\/uploads\/sites\/29\/2019\/02\/a-for-powertip.jpg\" align=\"left\" alt=\"Hey, Scripting Guy! Answer\" border=\"0\" title=\"Hey, Scripting Guy! Answer\" class=\"nearGraphic\" \/><a href=\"http:\/\/go.microsoft.com\/fwlink\/?linkid=68779&amp;clcid=0x409\"><img decoding=\"async\" height=\"288\" width=\"120\" src=\"http:\/\/img.microsoft.com\/library\/media\/1033\/technet\/images\/scriptcenter\/ad.jpg\" align=\"right\" alt=\"Script Center\" border=\"0\" title=\"Script Center\" class=\"farGraphic\" \/><\/a><\/p>\n<p>Hey, FS. You know what&rsquo;s the great thing about having kids? Oh, shoot; we were hoping you&rsquo;d know the answer to that one. However, we have to admit that if you <i>do<\/i> have kids you&rsquo;ll never have a dull moment. For example, the other night the Scripting Guy who writes this column was sitting around the house when the phone rang:<\/p>\n<p>&ldquo;Hello?&rdquo;<\/p>\n<p>&ldquo;Hey, Dad. Do you want to take me to the hospital?&rdquo;<\/p>\n<p>&ldquo;Uh, yeah, I guess.&rdquo;<\/p>\n<p>As it turned out, the Scripting Son and several of his friends were racing mountain bikes, and the Scripting Son took a corner a bit faster than he probably should have. Somehow &ndash; and nobody is totally sure how &ndash; when he did so his foot came off the pedal and the pedal, perhaps in an act of vengeance, carved a nice big gash in the back of his leg. The boys taped the leg up (by fortuitous coincidence the Scripting Son had just taken a first aid course a couple days ago), but when they checked the wound a half hour later and blood came gushing out they decided that maybe he should go have someone else &ndash; like, say a doctor &ndash; take a look at it. <\/p>\n<p>And so the Scripting Son and the Scripting Dad got to have a nice father-son outing to Evergreen Hospital in Kirkland. (True, a baseball game or even a trip to the zoo might have been better. But, hey a father-son outing is a father-son outing, right?) They then spent an hour and half in the emergency room, while 5 different people looked at the gash:<\/p>\n<table cellpadding=\"0\" cellspacing=\"0\" border=\"0\">\n<tbody>\n<tr>\n<td valign=\"top\" class=\"listBullet\">&bull;<\/td>\n<td class=\"listItem\">\n<p>One to do an initial diagnosis and numb the wound.<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" class=\"listBullet\">&bull;<\/td>\n<td class=\"listItem\">\n<p>One to clean the wound.<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" class=\"listBullet\">&bull;<\/td>\n<td class=\"listItem\">\n<p>One to come in and go, &ldquo;OK, that looks clean&rdquo;<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" class=\"listBullet\">&bull;<\/td>\n<td class=\"listItem\">\n<p>One to put in a few stitches.<\/p>\n<\/td>\n<\/tr>\n<tr>\n<td valign=\"top\" class=\"listBullet\">&bull;<\/td>\n<td class=\"listItem\">\n<p>One to put a bandage on the freshly-sewn wound.<\/p>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>And that doesn&rsquo;t count the three different people who collected the Scripting Son&rsquo;s address and phone number and &ndash; not incidentally, the Scripting Dad&rsquo;s insurance information.<\/p>\n<p>But all&rsquo;s well that ends well: the people at the hospital were extremely nice (all of them); the Scripting Son has a good story to tell people; and the Scripting Dad, who was supposed to do some work that evening, had the perfect excuse for not doing anything. Everything turned out perfect.<\/p>\n<p>Well, almost perfect; unfortunately, the Scripting Guy who writes this column can&rsquo;t use the Scripting Son&rsquo;s accident to get out of working today. (Not that he didn&rsquo;t try, mind you.) Which means we better see what we can do about answering today&rsquo;s question.<\/p>\n<p>Of course, as it turns out, we <i>can&rsquo;t<\/i> answer the question, at least not as asked: we couldn&rsquo;t figure out a way to programmatically open an attachment, either. But that&rsquo;s OK; we found a workaround. And even though FS has already completed the other steps in his multi-step process we decided other people might be interested in that as well; therefore this script includes code that not only opens each attachment but also copies all the data from each file and pastes that data into another spreadsheet. Enjoy!<\/p>\n<p>Oh, right; guess we should show you the script, shouldn&rsquo;t we? Here you go:<\/p>\n<pre class=\"codeSample\">Const olFolderInbox = 6<br \/>Const xlCellTypeLastCell = 11<\/pre>\n<pre class=\"codeSample\">Set objFSO = CreateObject(\"Scripting.FileSystemObject\")<\/pre>\n<pre class=\"codeSample\">Set objOutlook = CreateObject(\"Outlook.Application\")<br \/>Set objNamespace = objOutlook.GetNamespace(\"MAPI\")<br \/>Set objFolder = objNamespace.GetDefaultFolder(olFolderInbox)<\/pre>\n<pre class=\"codeSample\">Dim arrFiles()<br \/>intSize = 0<\/pre>\n<pre class=\"codeSample\">Set colItems = objFolder.Items<br \/>Set colFilteredItems = colItems.Restrict(\"[Subject] = 'Test Subject'\")<\/pre>\n<pre class=\"codeSample\">For Each objMessage In colFilteredItems<br \/>&nbsp;&nbsp;&nbsp; Set colAttachments = objMessage.Attachments <br \/>&nbsp;&nbsp;&nbsp; intCount = colAttachments.Count<br \/>&nbsp;&nbsp;&nbsp; If intCount &lt;&gt; 0 Then<br \/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; For i = 1 To intCount<br \/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; strFileName = \"C:\\Test\\\" &amp; objMessage.Attachments.Item(i).FileName<br \/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; objMessage.Attachments.Item(i).SaveAsFile strFileName<br \/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ReDim Preserve arrFiles(intSize)<br \/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; arrFiles(intSize) = strFileName<br \/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; intSize = intSize + 1<br \/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Next<br \/>&nbsp;&nbsp;&nbsp; End If<br \/>Next<\/pre>\n<pre class=\"codeSample\">Set objExcel = CreateObject(\"Excel.Application\")<br \/>objExcel.Visible = True<br \/>objExcel.DisplayAlerts = False<\/pre>\n<pre class=\"codeSample\">Set objWorkbook2 = objExcel.Workbooks.Add<br \/>Set objWorksheet2 = objWorkbook2.Worksheets(\"Sheet1\")<\/pre>\n<pre class=\"codeSample\">For Each strFile in arrFiles<br \/>&nbsp;&nbsp;&nbsp; Set objWorkbook = objExcel.Workbooks.Open(strFile)<br \/>&nbsp;&nbsp;&nbsp; Set objWorksheet = objWorkbook.Worksheets(\"Sheet1\")<\/pre>\n<pre class=\"codeSample\">&nbsp;&nbsp;&nbsp; Set objRange = objWorksheet.UsedRange<br \/>&nbsp;&nbsp;&nbsp; objRange.Copy<\/pre>\n<pre class=\"codeSample\">&nbsp;&nbsp;&nbsp; objWorksheet2.Activate<br \/>&nbsp;&nbsp;&nbsp; objworksheet2.Range(\"A1\").Activate<\/pre>\n<pre class=\"codeSample\">&nbsp;&nbsp;&nbsp; If objWorksheet2.Cells(1,1).Value &lt;&gt; \"\" Then<br \/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Set objRange2 = objWorksheet2.UsedRange<br \/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; objRange2.SpecialCells(xlCellTypeLastCell).Activate<br \/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; intNewRow = objExcel.ActiveCell.Row + 1<br \/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; strNewCell = \"A\" &amp;&nbsp; intNewRow<br \/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; objWorksheet2.Range(strNewCell).Activate<br \/>&nbsp;&nbsp;&nbsp; End If<\/pre>\n<pre class=\"codeSample\">&nbsp;&nbsp;&nbsp; objWorksheet2.Paste<br \/>&nbsp;&nbsp;&nbsp; objWorkbook.Close<br \/>&nbsp;&nbsp;&nbsp; <br \/>&nbsp;&nbsp;&nbsp; objFSO.DeleteFile(strFile)<br \/>Next<\/pre>\n<pre class=\"codeSample\">&nbsp;<\/pre>\n<p>As you can see, this is a relatively long, complicated script. Which can mean only one thing: we should probably leave now, before someone asks us to explain how it works.<\/p>\n<p>No, hey, just kidding. (Well, actually we <i>weren&rsquo;t <\/i>kidding, but the Scripting Editor is making us explain how the script works anyway.) We start out in pretty straightforward fashion, defining a constant named olFolderInbox (which will tell the script that we want to work with the Inbox folder) and a second constant named xlCellTypeLastCell (which we&rsquo;ll discuss in a little more detail later on). We next create an instance of the <b>Scripting.FileSystemObject<\/b>, an instance we&rsquo;ll immediately set aside and save for future use. Finally, we use these three lines of code to create an instance of the <b>Outlook.Application<\/b> object, bind to the MAPI namespace, and then make a connection to the Inbox folder:<\/p>\n<pre class=\"codeSample\">Set objOutlook = CreateObject(\"Outlook.Application\")\nSet objNamespace = objOutlook.GetNamespace(\"MAPI\")\nSet objFolder = objNamespace.GetDefaultFolder(olFolderInbox)<\/pre>\n<p>So are we ready to start retrieving emails? Well, just about. First we need to use these two lines of code to create a dynamic array named arrFiles and to assign the value 0 to a counter variable named intSize, a variable we&rsquo;ll use to periodically resize our array:<\/p>\n<pre class=\"codeSample\">Dim arrFiles()\nintSize = 0<\/pre>\n<p><i>Now<\/i> we&rsquo;re ready to start retrieving emails; in fact, that&rsquo;s what these two lines of code are for:<\/p>\n<pre class=\"codeSample\">Set colItems = objFolder.Items\nSet colFilteredItems = colItems.Restrict(\"[Subject] = 'Test Subject'\")<\/pre>\n<p>In line 1 we&rsquo;re using the <b>Items<\/b> property to retrieve a collection of all the emails found in the Inbox. And what are we doing in line 2? Well, as we noted earlier, we don&rsquo;t want <i>all<\/i> the emails found in the Inbox, we want only those emails that have a specific Subject line. In line 2, we&rsquo;re using the <b>Restrict<\/b> method to create a filtered collection, a collection in which all the items must have a <b>Subject<\/b> property equal to <i>Test Subject<\/i>.<\/p>\n<p>That brings us to this block of code:<\/p>\n<pre class=\"codeSample\"><pre class=\"codeSample\">For Each objMessage In colFilteredItems\n    Set colAttachments = objMessage.Attachments \n    intCount = colAttachments.Count\n    If intCount &lt;&gt; 0 Then\n        For i = 1 To intCount\n            strFileName = \"C:\\Test\\\" &amp; objMessage.Attachments.Item(i).FileName\n            objMessage.Attachments.Item(i).SaveAsFile strFileName\n            ReDim Preserve arrFiles(intSize)\n            arrFiles(intSize) = strFileName\n            intSize = intSize + 1\n        Next\n    End If\nNext<\/pre>\n<p>What we&rsquo;re doing here is looping through our filtered collection. For each email in the collection we use this line of code to create an object reference to all the attachments accompanying that email:<\/p>\n<pre class=\"codeSample\">Set colAttachments = objMessage.Attachments<\/pre>\n<p>Once we&rsquo;ve done that we use the <b>Count<\/b> property to determine the number of attachments in the Attachments collection, assigning that value to a variable named intCount:<\/p>\n<pre class=\"codeSample\">intCount = colAttachments.Count<\/pre>\n<p>We then check to see if intCount is equal to 0. If intCount <i>is<\/i> equal to 0 that means the message doesn&rsquo;t <i>have<\/i> any attachments; in that case we go back to the top of the loop and try again with the next email in the collection. <\/p>\n<p>On the other hand, if the Count is equal to anything <i>except<\/i> 0 then that means the message has at least one attachment. With that in mind, we set up a For Next loop that runs from 1 to the number of attachments accompanying the email:<\/p>\n<pre class=\"codeSample\">For i = 1 To intCount<\/pre>\n<p>As it turns out, there&rsquo;s no way to programmatically open an email attachment. (Or, more correctly, we should say that there&rsquo;s no way that <i>we<\/i> know of to programmatically open an email attachment. Such a method might very well exist; we just couldn&rsquo;t figure out what it was.) Therefore, we&rsquo;re going to cheat a little: instead of directly opening each attachment we&rsquo;re going to save those attachments to the hard disk. We&rsquo;ll then open each saved file, do our little copy-and-paste thing, and then close and delete each saved file. Clever, huh?<\/p>\n<p>Well, OK. Clever for <i>us<\/i>.<\/p>\n<p>At any rate, our first step to that end is to create a new file path for our first attachment; we do that by combining the string <b>C:\\Test\\<\/b> with the value of the attachment&rsquo;s <b>FileName<\/b> property. As soon as we&rsquo;ve done that we can then use the <b>SaveAsFile<\/b> method to save the file to disk:<\/p>\n<pre class=\"codeSample\">objMessage.Attachments.Item(i).SaveAsFile strFileName<\/pre>\n<p>We then execute these three lines of code:<\/p>\n<pre class=\"codeSample\"><pre class=\"codeSample\">ReDim Preserve arrFiles(intSize)\narrFiles(intSize) = strFileName\nintSize = intSize + 1<\/pre>\n<p>What we&rsquo;re doing here is using the <b>ReDim Preserve<\/b> statement to resize our array, taking care to preserve any data currently in that array. (Running ReDim without the Preserve statement would resize the array, but would also erase any data in the array.) We then add the path for our just-saved attachment to the array; in other words, arrFiles will eventually contain the complete path to each and every attachment we saved to the hard disk. And then we increment the value of intSize by 1. Why? Because the next time we resize our array we have to make sure the array can hold one item more than it can currently hold. This is an easy way of doing that.<\/p>\n<p>After all the attachments have been retrieved and saved we then get Microsoft Excel up and running, something we use this block of code for:<\/p>\n<pre class=\"codeSample\">Set objExcel = CreateObject(\"Excel.Application\")\nobjExcel.Visible = True\nobjExcel.DisplayAlerts = False\n\nSet objWorkbook2 = objExcel.Workbooks.Add\nSet objWorksheet2 = objWorkbook2.Worksheets(\"Sheet1\")<\/pre>\n<p>As you can see, we kick things off by creating an instance of the <b>Excel.Application<\/b> object, then setting the <b>Visible<\/b> property to True; that gives us a running instance of Excel that we can see onscreen. We then set the <b>DisplayAlerts<\/b> property to False. Why? Well, we&rsquo;re going to repeatedly copy data from a workbook and then close that workbook; if we don&rsquo;t set DisplayAlerts to False then every time we close a workbook Excel will say, &ldquo;There is a large amount of Information on the Clipboard. Do you want to be able to paste this information into another program later?&rdquo; Truthfully, we don&rsquo;t really care; we just want to avoid having to deal with this dialog box. By setting DisplayAlerts to False we don&rsquo;t see this dialog box; instead, Excel simply goes with the default choice (<b>Yes<\/b>).<\/p>\n<p>Once that&rsquo;s done we use the <b>Add<\/b> method to add a new workbook to our instance of Excel, then bind to the first worksheet in that workbook. It&rsquo;s at that point that things <i>really<\/i> get interesting.<\/p>\n<p>Oh, sorry; we&rsquo;re watching a baseball game on TV. But things get pretty interesting with our script, too.<\/p>\n<p><i>How<\/i> interesting? Well, to begin with, we set up a For Each loop to loop through all the files paths in the array arrFiles:<\/p>\n<pre class=\"codeSample\">For Each strFile in arrFiles<\/pre>\n<p>Inside that loop we use these two lines of code to open the file and then bind to the first worksheet in that file:<\/p>\n<pre class=\"codeSample\"><pre class=\"codeSample\">Set objWorkbook = objExcel.Workbooks.Open(strFile)\nSet objWorksheet = objWorkbook.Worksheets(\"Sheet1\")<\/pre>\n<p>After we&rsquo;ve done that we can use the <b>UsedRange<\/b> property to select all the data on the worksheet, then use the <b>Copy<\/b> method to copy all that data to the Clipboard. That&rsquo;s what these two lines are for:<\/p>\n<pre class=\"codeSample\"><pre class=\"codeSample\">Set objRange = objWorksheet.UsedRange\nobjRange.Copy<\/pre>\n<p>We then use two more lines of code to activate our original worksheet (the one we&rsquo;re going to paste the data into) and to make cell A1 on that sheet the active cell:<\/p>\n<pre class=\"codeSample\">objWorksheet2.Activate\nobjworksheet2.Range(\"A1\").Activate<\/pre>\n<p>At this point things get a little tricky. If we were working with only one Excel file all we&rsquo;d have to do is call the <b>Paste<\/b> method and we&rsquo;d be done. However, we&rsquo;re most likely going to be working with multiple Excel files. Suppose we paste in the data from the first file, and this data fills up the first 12 rows in the spreadsheet. When we go to paste in data from the next file, we have to start the paste operation in row 13. But how in the world do we do <i>that<\/i>?<\/p>\n<p>Well, the first thing we do is check to see if cell A1 is empty; if it is, then we <i>can<\/i> just paste data into the worksheet:<\/p>\n<pre class=\"codeSample\">If objWorksheet2.Cells(1,1).Value &lt;&gt; \"\" Then<\/pre>\n<p>In fact, that&rsquo;s what will happen when we go to paste in data from our first file: because cell A1 will be empty we can bypass this If Then statement and simply paste in the data. From that point on, however, cell A1 will no longer be empty. Because of that, we need to figure out where we <i>can<\/i> paste our new set of data. That&rsquo;s what this block of code is for:<\/p>\n<pre class=\"codeSample\"><pre class=\"codeSample\">Set objRange2 = objWorksheet2.UsedRange\nobjRange2.SpecialCells(xlCellTypeLastCell).Activate\nintNewRow = objExcel.ActiveCell.Row + 1\nstrNewCell = \"A\" &amp;  intNewRow\nobjWorksheet2.Range(strNewCell).Activate<\/pre>\n<p>What we&rsquo;re doing here is using the <b>UsedRange<\/b> property to create a <b>Range<\/b> object that encompasses all the cells in the spreadsheet that contain data. Once that&rsquo;s done we use the <b>SpecialCells<\/b> method to go to the very last cell in that range; note the use of the constant xlCellTypeLastCell. And what do we do after we reach the last cell in the range? Why, we use the <b>Activate<\/b> method to make that cell the active cell in the spreadsheet.<\/p>\n<p>Of course, that&rsquo;s not really what we want; after all, that cell has data in it. What we want to do is drop down to the next row, and make cell A in that row the active cell. One way to do that (and there <i>are<\/i> other ways) is to determine the current row and then add 1 to it; that&rsquo;s what this line of code does:<\/p>\n<pre class=\"codeSample\">intNewRow = objExcel.ActiveCell.Row + 1<\/pre>\n<p>We then tack the letter <i>A<\/i> onto the front of that value (e.g., A13) giving us a cell reference that we can use with the Range property. And that&rsquo;s exactly what we do here; we create a new range and then make that cell (e.g., cell A13) the active cell:<\/p>\n<pre class=\"codeSample\">strNewCell = \"A\" &amp;  intNewRow objWorksheet2.Range(strNewCell).Activate<\/pre>\n<p>Once we&rsquo;ve done that we can finally call the Paste method and paste in our data. We close the saved attachment file, then use this line of code to delete that file from the folder C:\\Test:<\/p>\n<pre class=\"codeSample\">objFSO.DeleteFile(strFile)<\/pre>\n<p>And then it&rsquo;s back to the top of the loop, where we repeat the process with the next file path in arrFiles.<\/p>\n<p>That should do it, FS; let us know if you run into problems. Oh, and let us know if you need to go to the emergency room and get your leg stitched up: we&rsquo;ve got plenty of experience doing that as well.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Hey, Scripting Guy! We recently implemented a scheme whereby Team Leads or Contract Sponsors may request server access for their Team members by submitting an Excel spreadsheet. To this end, I proposed a script that will open Outlook, look for items in the Inbox that contain a particular Subject line (we will pick the wording [&hellip;]<\/p>\n","protected":false},"author":595,"featured_media":87096,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[1],"tags":[212,49,3,5],"class_list":["post-55293","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-scripting","tag-microsoft-outlook","tag-office","tag-scripting-guy","tag-vbscript"],"acf":[],"blog_post_summary":"<p>Hey, Scripting Guy! We recently implemented a scheme whereby Team Leads or Contract Sponsors may request server access for their Team members by submitting an Excel spreadsheet. To this end, I proposed a script that will open Outlook, look for items in the Inbox that contain a particular Subject line (we will pick the wording [&hellip;]<\/p>\n","_links":{"self":[{"href":"https:\/\/devblogs.microsoft.com\/scripting\/wp-json\/wp\/v2\/posts\/55293","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/devblogs.microsoft.com\/scripting\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/devblogs.microsoft.com\/scripting\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/scripting\/wp-json\/wp\/v2\/users\/595"}],"replies":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/scripting\/wp-json\/wp\/v2\/comments?post=55293"}],"version-history":[{"count":0,"href":"https:\/\/devblogs.microsoft.com\/scripting\/wp-json\/wp\/v2\/posts\/55293\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/scripting\/wp-json\/wp\/v2\/media\/87096"}],"wp:attachment":[{"href":"https:\/\/devblogs.microsoft.com\/scripting\/wp-json\/wp\/v2\/media?parent=55293"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/scripting\/wp-json\/wp\/v2\/categories?post=55293"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/scripting\/wp-json\/wp\/v2\/tags?post=55293"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}