问题描述
我想通过命令提示符启动一个openoffice模板(.ott).我的template.ott打开后,其名称为Untitled 1.odt
I like to start a openoffice template (.ott) via my command prompt.Once my template.ott has opened it is called Untitled 1.odt
我需要的是获取template.ott的位置的方法(该模板的目录路径为Untitled 1.odt).我想在Untitled 1.odt
What I need is way to get the location of the template.ott (the path to the directory of the template that made Untitled 1.odt). I want to use that path in a macro in Untitled 1.odt
问题总结:因此,当我在无标题1.odt"中有一个宏时,如何获取template.ott的位置?
The question summarized:So when I have a macro in Untitled 1.odt, how do I get the location of the template.ott?
我使用OpenOffice Writer.
I use OpenOffice Writer.
编辑:我在Openoffice Basic中编写宏.
I write macros in Openoffice Basic.
推荐答案
来自Andrew Pitonyak的宏文档:
Sub GetTemplatePath
Dim oDocProps
oDocProps = ThisComponent.getDocumentProperties()
MsgBox "TemplateURL " & oDocProps.TemplateURL
End Sub
这篇关于openoffice模板启动获取目录宏的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!