Hi Mangesh, On Tue, Jan 08, 2013 at 11:18:17AM +0000, Shukla, Mangesh wrote: > Hi Ariel, Thanks for the quick reply. Actually I intend to implement > this just as you describe. I intend to create an Extension to add my > own Menu and toolbar items. Also I will be adding some Macros > (functions which appear in the functions wizard), to the extension. > The intention to add these UI items, is to transfer the call to the > external application, so that the data from the external application > can be populated in the spreadsheet. The actual functionality lies in > the external application, and I need to get the calls redirected to > the external application as and when the user invokes the menu > items/toolbar items/macros in the extension.
Then the proper way to do this seems not to intercept the dispatch framework; simply implement an extension that communicates to the external application when it is asked to dispatch; the steps would be: - the dispatch framework asks your extension to dispatch a certain URL when the user executes a menu/toolbar item - when dispatching, your extension communicates to the external application an retrieves the information to populate the spreadsheet The key point here is the communication between the extension and the external application. The Zotero extension talks to Zotero, a bibliographic program for Firexfox (or standalone), does this via a socket (AFAIK). Another thing to consider: is this external application already running on the target system, or are you planning to install the application together with the extension? > I have checked the link about the dispatch framework. However it is > not clear to me, how it could be made to work with a C++ client. Could > you direct me to some samples to illustrate the behavior. IIRC there is an example in the SDK, but it's written in Java, and is rather complicated/obscure. Anyway, I wouldn't suggest to follow this path of intercepting dispatches in the external application; better implement an extension that "talks to" this external application. There are several drawbacks for the other approach: - the external application will have to be linked to the URE - the external application will have to bootstrap OpenOffice, or connect to a running instance - etc Regards -- Ariel Constenla-Haile La Plata, Argentina
pgpkvo23C2esF.pgp
Description: PGP signature
