ItemId not valid after email sent - outlook-addin

This SO question answers part of my question - when I save an email I can retrieve its ItemId but as soon as it's sent the ItemId is invalid and a request to to the Outlook rest api to retrieve the email returns a 404.
My question then is how do I subsequently identify the email I just sent if the ItemId is different?

You can stamp the message with your own custom property - it will be preserved when the message is moved to the Sent Items folder. You will be able to search on that property.

Related

Discrepancy between attachment contentType and attachment names on different clients for item attachments

When using the officejs api (v1.8), we're observing differences between item attachment metadata when using different clients when looking at the same email.
Outlook for Mac (v16.31 19111002)
- AttachmentDetails.name properties include the file suffix. E.g. (fileName).(eml, ics, vcf)
- AttachmentDetails.contentType returns correctly (message/rfc822, text/calendar, text/directory)
- AttachmentContent.format incorrectly returns .eml for all item attachment types
OWA (Chrome)
- AttachmentDetails.name properties does not include the file suffix
- AttachmentDetails.contentType incorrectly returns undefined
- AttachmentContent.format returns .(eml,iCalendar) as expected for all item attachment types
- This ONLY happens when viewing emails with item attachments sent from Outlook Desktop on Windows. Example build (1911 12228.20332)
What is the expected behavior when reading attachment metadata on different clients?
In addition as per this prior stackOverflow post, are there any plans to support getAttachmentContentAsync with contact item attachments?

WHMCS show single ticket reply by last update

I want make a new file to call a ticket replies from db and adding feature for showing a single reply only by reply id or reply time for example if called a URL like
history.php?tid=844130&c=1uT0TR8y&lastreply=1222
How I can do that?

Email alias from LegacyExchangeDN - LDAP

I am working with Exchange EWS API. The API returns me a value which is legacyExchangeDN. The value looks like this -
/o=Amazon/ou=Exchange Administrative Group (FYDXXXXXXXXDLT)/cn=Recipients/cn=b08141c097dfd32432klbva43595-email-list
The value is also cropped in some cases (last few characters are not returned by the API)
How can I convert this value into meaningful email address?
Usually you would see this when you make a findItems request because Exchange doesn't resolve the Native (EX) Addresses back to SMTP addresses in this operation. So if you make a GetItem (or Load/Loadpropertiesforitems) request on the particular item you want to look at it as long as that address can be resolve in the GAL (eg that user or object hasn't been deleted) it should return the resolved address. The other option is to use the ResolveName operation https://msdn.microsoft.com/en-us/library/office/dn645423(v=exchg.150).aspx

Debugging K2 workflow - how to view data associated with error conditions?

I have a K2 Blackpearl workflow. In the workflow I populate a process data field with email addresses pulled from a SharePoint list. Using the Text - Join function with the SP List's SmartObject's GetList method for the values and a semi-colon for the separator.
In theory, this should produce a well-formatted string with multiple addresses for the "To" line of the E-mail event. However, I keep receiving a "The specified string is not in the form required for an e-mail address." at the point where the workflow should attempt to send an email.
I've tried using the string "john.doe#company.com;jane.dove#company.com;abc.def#company.com" directly and I've tried splitting the string on the semi-colons in the Activity's destination set. In the first case, there is one instance trying to send the email. In the second instance, the emails are resolved to users and though I select the "ActivityInstanceDestUserEmail" for the "To" line, I still get the error message.
We are using K2 Blackpearl 4.6 with a SharePoint 2010 farm configured strictly for Claims authentication. The users to which I wish to send the email have valid email addresses if resolved using the K2SPS provider, but when the emails are resolved into destination slots, they are resolved into accounts with the K2 provider. I'm guessing that this is the problem with my second method for sending the email. But the first, putting the whole string in the "To" line should have worked it is straight email addresses - no resolving to users is needed.
What am I doing wrong? Is there another way to accomplish this?
Changes in the configuration of our customer security provider, labelled "K2SPS" seem to have resolved the problem - at least for now.

email header "from" containing first and last names, not sender's email

I'm reading emails from pop3 server with zend mail component.
What I want is to know who is sent this email and when I try $message->from I see "FirstName LastName" without senders email.
I do print_r($message->getHeaders()) and do not see sender's email in any header from this email.
I thought that senders email is required and always must be set. Anything wrong here?
Is that possible to have email with "from" header with only First/Last name without email?
As per my comment:
if you print_r() a valid from header and the address is in angle brackets, you may only see it by viewing the HTML source, because the angle brackets and email address may be treated as an (albeit unrecognised) HTML tag, by the browser.
However, if anyone encounters this issue in the future (and the email address does not show in the HTML source), it is worth bearing in mind that the sender could have sent an email without a From: address, even though that is technically invalid.
Yes, this is totally possible. There are 2 usually "FROM" addressess with every email. 99% of the time, these are the same values, but they can be different. There is the MAIL FROM address that is used during the SMTP session, that issues the MAIL FROM command. Then, there is the FROM address found in the email message headers (this FROM address is sent during the SMTP DATA command). This is how you can get email spoofing.
Think of it this way (in the snail mail physical world). You can have a FROM address on the outside of an envelope (this would be equiv to the MAIL FROM command). This is supposed to be the person sending the message. You can then have a FROM value that is different on the letter head that is inside the envelope. This would be the FROM value you are seeing in the email headers.
Here is an example of some raw headers without a FROM address
From: "Steve James"
To: "John Doe" <you#yourcompany.com>
Date: Fri, 24 Feb 2012 07:43:40 -0800
Subject: Here is the progress report
....
Hopefully I didn't make that about as clear as mud.
--
Use the following format:
Firstname Lastname <vasya#poupkine.com>