I wrote code to read emails with Mailkit, in the Mailkit there is a way to read first email, but i couldn't find a way to read subject of last recent email
using (var client = new ImapClient())
{
client.Connect(EXT_IMAP_SERVER, EXT_IMAP_PORT, true);
client.Authenticate(EXT_USERNAME, EXT_PASSWORD);
var inbox = client.Inbox;
inbox.Open(FolderAccess.ReadWrite);
var LAST_EMAIL = inbox.FirstUnread;// ****** here is my issue ******
var LAST_MSG = client.Inbox.GetMessage(LAST_EMAIL);
inbox.AddFlags(LAST_EMAIL, MessageFlags.Seen, true);
Console.WriteLine(LAST_MSG.Subject);
client.Disconnect(true);
}