Search The ForumSearch   RegisterRegister  LoginLogin

MailBee.NET IMAP

 AfterLogic Forum : MailBee.NET IMAP
Subject Topic: Search Method Post ReplyPost New Topic
Author
Message << Prev Topic | Next Topic >>
loredano
Newbie
Newbie
Avatar

Joined: 11 April 2018
Location: Italy
Online Status: Offline
Posts: 15
Posted: 11 June 2019 at 2:42am | IP Logged Quote loredano

Hi,
Is it possible search for a value of custom Header using the Imap.Search Method (Boolean, String, String)?

In other words we send a pec mail and assign a MessageId to it; the provider use the value of MessageId and assign it to an header "XRiferimentoMessageId" in the replay mail to the sent mail.
So I have to search on the server (without download....) the replay mail by XRiferimentoMessageId (in msg.Headers["XRiferimentoMessaggeId"] = MessageId,that I know because I have generate it).

Regards
Loredano
Back to Top View loredano's Profile Search for other posts by loredano
 
Alex
AfterLogic Support
AfterLogic Support
Avatar

Joined: 19 November 2003
Online Status: Offline
Posts: 2206
Posted: 11 June 2019 at 3:24am | IP Logged Quote Alex

Hi,

Yes, you can use searchCondition (second parameter of Search method) to something like "HEADER MESSAGE-ID <1234567890@domain>".

Will this work or not, depends on whether the server internally support this or not. For instance, Gmail does support this (I just checked). But there is no guarantee that any arbitrary server will support this.

Also, be sure to specify the entire Message-ID value. Substring (e.g "HEADER MESSAGE-ID 1234567890") won't work.

Regards,
Alex
Back to Top View Alex's Profile Search for other posts by Alex
 

If you wish to post a reply to this topic you must first login
If you are not already registered you must first register

  Post ReplyPost New Topic
Printable version Printable version

Forum Jump

Powered by Web Wiz Forums version 7.9
Copyright ©2001-2004 Web Wiz Guide