有的时候希望查询一个服务或者接口有哪些方法通过msgbox查看不太方便,于是想到一个方法将其输出到odt文档然后通过查找功能查找即可
REM ***** BASIC *****
Sub Main
InsertStringToOdt(thiscomponent.dbg_methods)
End Sub
Function InsertStringToOdt(str as string)
rem get access to the document
document = ThisComponent.CurrentController.Frame
dispatcher = createUnoService("com.sun.star.frame.DispatchHelper")
oText = ThisComponent.GetText()
oCurs = ThisComponent.getCurrentController().getViewCursor()
oText.insertString(oCurs, str, False)
rem ----------------------------------------------------------------------
dispatcher.executeDispatch(document, ".uno:InsertPara", "", 0, Array())
End Function
本文介绍了一种将服务或接口的方法列表输出到ODT文档的方法,以便于使用文档的查找功能进行快速检索。该方法利用了VBA编程实现。
2224

被折叠的 条评论
为什么被折叠?



