Paste html from Clipboard
时间:2011-06-11 来源:誓言的爱
Paste html from Clipboard 可解决中文乱码问题。
MemoryStream ms = Clipboard.GetData("Html Format") as MemoryStream;
if (ms == null)
{
return;
}
ms.Position = 0;
byte[] vBytes = new byte[ms.Length];
ms.Read(vBytes, 0, (int)ms.Length);
string strFullHtml = Encoding.UTF8.GetString(vBytes); // utf-8
相关阅读 更多 +