ASP 经典 CDO 电子邮件在 textbody 中使用 UTF-8 [英] ASP classic CDO Email messaging use UTF-8 in textbody

查看:18
本文介绍了ASP 经典 CDO 电子邮件在 textbody 中使用 UTF-8的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何使用 UTF-8 字符集发送电子邮件.请注意,我需要在 textbody 而不是 htmlbody 中使用它.

How can i send email by using UTF-8 charset. Kindly note that I need to use it in textbody and not in htmlbody.

如果我在 htmlbody 中使用它,但当我尝试使用 textbody 时,一切正常.我得到了 aschii 代码字符

Everythings working fine if I uses it in htmlbody but when I tried to used textbody. I got aschii code character

objCDOMailer.TextBody  = "test - Rozwiązanie"  >> having a problem
objCDOMailer.HTMLBody  = "test - Rozwiązanie"  >> dont have a problem

我对上面两个都使用了下面的代码.

I used the code below for both above.

  objMail.BodyPartCharset = "UTF-8"

推荐答案

使用

bjCDOMailer.TextBodyPart.Charset = "utf-8" 

用于字符编码.

objCDOMailer.BodyPart.Charset = "utf-8" 
objCDOMailer.HTMLBodyPart.Charset = "utf-8"

上面的不工作.

这篇关于ASP 经典 CDO 电子邮件在 textbody 中使用 UTF-8的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆