//get BBS Content
string strSubject = "【" + drpType.SelectedValue.Trim() + "】" + txtTitle.Text.Trim();
StringBuilder sbContent = getMailContent(strSubject);
//print
Response.Clear();
Response.Buffer = true;
Response.Charset = "GB2312";
Response.AppendHeader("Content-Disposition", "attachment;filename=FileName.doc");
Response.ContentEncoding = System.Text.Encoding.UTF8;
Response.Write(sbContent.ToString());
Response.End();
string strSubject = "【" + drpType.SelectedValue.Trim() + "】" + txtTitle.Text.Trim();
StringBuilder sbContent = getMailContent(strSubject);
Response.Clear();
Response.Buffer = true;
Response.Charset = "GB2312";
Response.AppendHeader("Content-Disposition", "attachment;filename=FileName.doc");
Response.ContentEncoding = System.Text.Encoding.UTF8;
Response.Write(sbContent.ToString());
Response.End();
注意:
ContentEncoding要选择UTF8
相关文章
暂无评论...