![]() The first step is to obtain a .XDispatchHelper interface.Īrgs1. How to translate such a code in C++ ? The problem is to handle the dispatcher. executeDispatch (document, ".uno:FontHeight", "", 0, args4 ( ) ) end sub executeDispatch (document, ".uno:Bold", "", 0, args2 ( ) ) rem -ĭim args4 ( 2 ) as new com. executeDispatch (document, ".uno:InsertText", "", 0, args1 ( ) ) rem -ĭim args2 ( 0 ) as new com. Frameĭispatcher = createUnoService ( ".DispatchHelper" ) rem -ĭim args1 ( 0 ) as new com. Rem -ĭim document as object dim dispatcher as object rem -ĭocument = ThisComponent. 'Listing 2 OOoBasic and the Dispatcher with Macro Recorder REM ***** BASIC ***** See The recorder and UNO dispatch calls section for a discussion on recording UNO Dispatch commands versus writing API calls.įor instance if you have a Apache OpenOffice Writer document, and you record a macro when inserting text and formatting it, you obtain something like: If you record a macro, you obtain a OOoBasic code which uses the dispatcher instead of direct UNO call. This is a very straightforward way but probably internationalization dependent. The first way we want to examine is the use of the dispatcher before using direct UNO calls in next section. ![]() Using the Dispatcher and recording Macros 9.1.2 Path of IDL-tree with a Introspection Tool.9.1.1 Path of IDL-tree with a textual Description.8 Translating Java Code into C++ (inserting an Image). ![]()
0 Comments
Leave a Reply. |