4 messages in org.openoffice.fr.prog[prog] Pilotage de Calc avec VBScript...
FromSent OnAttachments
Patrice AGUILHONAug 27, 2004 1:18 am 
Laurent GodardAug 27, 2004 1:30 am 
Patrice AGUILHONAug 27, 2004 2:12 am 
Laurent GodardAug 27, 2004 3:00 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:[prog] Pilotage de Calc avec VBScript sous WindowsActions...
From:Patrice AGUILHON (p.ag@VACHAUD.COM)
Date:Aug 27, 2004 1:18:57 am
List:org.openoffice.fr.prog

Bonjour,

Ne sachant pas si mon message est arrivé sur la liste, je me permet de le
renvoyer.

Je souhaite inserer une image dans calc avec VisualBasic. J'ai réussi mais l'image est representée par un point. Ma question est xcomment faire pour modifier la taille d'une image ou inserer
une image avec sa taille. Ci joint une partie du code que j'utilise

Set objServiceManager=WScript.CreateObject("com.sun.star.ServiceManager") Set objDesktop=objServiceManager.createInstance("com.sun.star.frame.Desktop")

Dim args() Set calc=objDesktop.loadComponentFromURL("file:///C|/scalc.xls","_blank",0,args) Set sheets=calc.Sheets

Set sheet=sheets.getbyindex(0)

set oGraph = calc.createInstance("com.sun.star.drawing.GraphicObjectShape") oGraph.GraphicURL = "file:///p:/fliba/fg013085.jpg"

rem partie qui est en erreur rem TheSize as new com.sun.star.awt.Size rem TheSize.width=1440 rem TheSize.height=1440

oGraph.setsize(theSize)

calc.getDrawPages().getByIndex(0).add(oGraph)

Merci de vos reponses Patrice