Beefy Boxes and Bandwidth Generously Provided by pair Networks
Just another Perl shrine
 
PerlMonks  

Re: Excel: is there a way to set a background picture using Perl?

by davies (Prior)
on Feb 19, 2019 at 12:19 UTC ( [id://1230164]=note: print w/replies, xml ) Need Help??


in reply to Excel: is there a way to set a background picture using Perl?

If you're prepared to use Win32::OLE, it's quite simple:

use strict; use warnings; use Win32::OLE; my $xl = Win32::OLE->new('Excel.Application'); $xl->{Visible} = 1; my $wb = $xl->Workbooks->Add; for my $nSht (2..$wb->Sheets->{Count}) { $wb->Sheets(2)->Delete; } my $filename = 'x:\data\internet-memes-hopscotch-accepted.jpg'; # Make + this whatever you want $wb->sheets(1)->SetBackgroundPicture({Filename => $filename});

If not, I hope this gives some clue as to what to look for in modules I don't use.

Regards,

John Davies

Replies are listed 'Best First'.
Re^2: Excel: is there a way to set a background picture using Perl?
by Darkwing (Beadle) on Feb 21, 2019 at 07:27 UTC
    Thanks. This works for me.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others examining the Monastery: (3)
As of 2024-04-20 09:50 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found