0 votes
by (150 points)

Hello, i am stuck with an issue where i need to update a mail's subject from my .net code with the imapClient.

With the ewsClient i can use EwsMessageMetadata to update the message. With the imapClient the only way to do so seems to be to delete the current message and store the updated message.

This works BUT seems to give the newly stored message a new (higher) sequence-number; which is unwanted because i use ImapMessageSet-range to only get a specific range of e-mails. The updated/newly stored message will not show because it has a new sequence number which is ouside the bounds of the sequence-range at that time.

How to deal with this for imap?

Applies to: Rebex Secure Mail

1 Answer

0 votes
by (147k points)
selected by
 
Best answer

Unfortunately, IMAP does not support modifying messages. This is a limitation of the IMAP protocol itself, which means there is no way around it.

Consider modifying the process a bit - ImapMessageSet has Add method that makes it possible to add additional IDs or ranges.

...