简体   繁体   中英

IMAP Sort in c#

How can I send this command:

var command = "SEARCH CHARSET UNICODE BODY {5}";
var command2= "icône";

to an imap server with c#

I am actually trying to use something like this:

 this._sslStream.Write(System.Text.Encoding.UTF8.GetBytes(stamp + ((stamp.Length > 0) ? " " : "") + command + "\r\n\r\n"), 0, stamp.Length + ((stamp.Length > 0) ? 1 : 0) + command.Length + 2);

I'm blocked, without accent it is ok, with accent, I get no answer

当编码为UTF-8时, "icône"占用6个字节,而不是命令( {5} )中指示的5个字节。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM