【发布时间】:2011-01-02 15:08:42
【问题描述】:
我想将通过 OpenOffice.org UNO 创建的 TextDocument 保存到磁盘上的文件中。最好的方法是什么?
编辑:这是我最终使用的 C# 代码。 document 是 XTextDocument。
protected void Save (string path)
{
string url = "file://" + path;
PropertyValue [] propertyValues = {
new PropertyValue {
Name = "FilterName",
Value = new Any ("writer8")
}
};
((XStorable) document).storeAsURL (url, propertyValues);
}
【问题讨论】:
-
我在用 C# 工作,但如果你用其他语言回答,我可以将它翻译成 C#。
-
小心你想要的 - ++++[>+++++[-]+[>+>+ >[>-]>>>[-]++>[-]+>>>+[[-]++++++> >>]>-]+<.>---->>>>[>>>[-]++ +++++++-[-[-]+[+]
-
不知道 OOo 在 BF 中是否可以编写脚本。
标签: c# openoffice.org uno