Beefy Boxes and Bandwidth Generously Provided by pair Networks
Problems? Is your data what you think it is?

Re: Win32::OLE PowerPoint Shapes

by jsprat (Curate)
on Oct 25, 2003 at 05:26 UTC ( #302029=note: print w/replies, xml ) Need Help??

in reply to Win32::OLE PowerPoint Shapes

Perl knows not what msoShapeRectangle is. You need to import the constants from the Office type library or supply them yourself.

Try something like this

use Win32::OLE; use Win32::OLE::Const 'Microsoft Office'; print msoShapeRectangle . ":" . msoShapeOval; __END__ results: 1:9

Replies are listed 'Best First'.
Re: Re: Win32::OLE PowerPoint Shapes
by Anonymous Monk on Oct 27, 2003 at 14:01 UTC
    Thankyou. I've got the shape added but now I'm stumped on how to set the fill color. Based on a ppt macro that does the same thing I think the perl code should be something like:
    $colorBox->Fill->{ForeColor} = ({Red=>255, Green=>255, Blue=>153});
    but this results in the error:
    Win32::OLE(0.1601) error 0x80020005: "Type mismatch" in PROPERTYPUT "ForeColor" at build_ql.prl line 121
    Any suggestions ?

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://302029]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others pondering the Monastery: (4)
As of 2021-01-22 04:22 GMT
Find Nodes?
    Voting Booth?