List Info

Thread: service css.graphic.GraphicProvider - exporting as OutputStream impossible




service css.graphic.GraphicProvider - exporting as OutputStream impossible
user name
2006-06-18 22:59:31
 Hi all,

consider the following code:

REM  *****  BASIC  *****

Sub TestGraphicProvider

'get the graphic obj from file
oProvider =
createUnoService("com.sun.star.graphic.GraphicProvider
")
Dim oPropsIN(0)as new com.sun.star.beans.PropertyValue
oPropsIN(0).Name  = "URL"
oPropsIN(0).Value = "file:///home/paolo/img.png"
oGraph = oProvider.queryGraphic(oPropsIN())

oPipe = CreateUnoService("com.sun.star.io.Pipe")
Dim oPropsOUT(1)as new com.sun.star.beans.PropertyValue
oPropsOUT(0).Name  = "OutputStream"
oPropsOUT(0).Value = oPipe
oPropsOUT(1).Name  = "MimeType"
oPropsOUT(1).Value = "image/bmp"
oProvider.storeGraphic(oGraph, oPropsOUT())

print oPipe.available 'always 0
	
End Sub


In my tests, the result of oPipe.available was always 0 were
I woud have 
espected > 0
Perhaps am I missing something fundamental?

Thank you for any help
Paolo M




------------------------------------------------------------
---------
To unsubscribe, e-mail: dev-unsubscribeapi.openoffice.org
For additional commands, e-mail: dev-helpapi.openoffice.org

[1]

about | contact  Other archives ( Real Estate discussion Medical topics )