我必须在每个文档的末尾添加一个表。但是文本永远不会在文档末尾结束
有没有关于如何在文档末尾追加此表的提示?Thnx
txt = ["xxxxxx","yyyyyy","zzzzzz"]
d = Document(os.path.join(path,i))
table = d.add_table(rows=3, cols=1)
for j in range(3):
row = table.rows[j]
row.cells[0].text = txt[j]
d.save(os.path.join(path,i))
输出:
Tags:
目前没有回答
相关问题 更多 >
编程相关推荐