2 messages in org.openoffice.fr.progExtensions OOo : éxécution d'une mac...
FromSent OnAttachments
vata...@no-log.orgJun 20, 2008 3:20 am 
AladdinJun 25, 2008 2:09 am 
Actions with this message:
Paste this link in email or IM:
Paste this link in email or IM:
Atom feed for this thread
Paste this URL into your reader:
Subject:Extensions OOo : éxécution d'une macro au déclenchement d'un évènement de l'applicationActions...
From:vata...@no-log.org (vata@no-log.org)
Date:Jun 20, 2008 3:20:48 am
List:org.openoffice.fr.prog

Bonjour,

Actuellement j'ai une macro dont l'exécution est commandée par le déclenchement d'un événement au niveau de l'application ou d'un document ('Ouverture de document', 'Démarrage de l'application'...).

Est-il possible de conserver ce association événement<->exécution dans une extension générée avec l'outil BasicAddonBuidler?

J'ai déjà fait un premier essais comme ceci :

* création d'un fichier Events.xcu dans mon extension :

<?xml version="1.0" encoding="UTF-8"?> <oor:component-data xmlns:oor="http://openoffice.org/2001/registry" xmlns:xs="http://www.w3.org/2001/XMLSchema" oor:name="Events" oor:package="org.openoffice.Office"> <node oor:name="ApplicationEvents"> <node oor:name="Bindings"> <node oor:name="OnLoad" oor:op="replace"> <prop oor:name="BindingURL" oor:type="xs:string"> <value>vnd.sun.star.script:library_name.module_name.function_name?language=Basic&amp;location=application</value> </prop> </node> </node> </node> </oor:component-data>

* déclaration du fichier xcu dans le fichier manifest.xml :

<?xml version="1.0" encoding="UTF-8"?> <manifest:manifest> <manifest:file-entry manifest:full-path="ConvertLinks/" manifest:media-type="application/vnd.sun.star.basic-library"/> <manifest:file-entry manifest:full-path="pkg-desc/pkg-description.txt" manifest:media-type="application/vnd.sun.star.package-bundle-description"/> <manifest:file-entry manifest:full-path="Addons.xcu" manifest:media-type="application/vnd.sun.star.configuration-data"/> <manifest:file-entry manifest:full-path="Events.xcu" manifest:media-type="application/vnd.sun.star.configuration-data"/> <manifest:file-entry manifest:full-path="Office/UI/DrawWindowState.xcu" manifest:media-type="application/vnd.sun.star.configuration-data"/> ...etc

mais sans succès.

Merci