python-docx创建Word文档报错ValueError: All strings must be XML compatible: Unicode or ASCII, no NULL bytes
python-docx创建Word文档报错ValueError: All strings must be XML compatible: Unicode or ASCII, no NULL bytes or control characters
这个怎么解决?
网友回复
方法一:
字符前加u,例如:
p = document.add_paragraph(u"哈哈 ")
方法二:编码转换
p = docume...
点击查看剩余70%