I can't help you with the module and exporting variables, but I can tell you
what to do for Excel Charts.

Try this piece of code:

########################################
# With control of Excel and Data already in there.

my $Chart = Excel->Charts->Add;
$Chart->{ChartType} = xlLine;
$Chart->SetSourceData({Source => $Range, PlotBy => xlColumns});

#  $Range has already been defined as the range of cells containing data
(including Column Headings).

$Chart->{HasTitle} = 1;
$Chart->ChartTitle->{Text} = "Place Text Here";
my $ChartObj = $Sheet->ChartObjects;

#  This isn't used any where else, so I don't know if it's needed or not.

$Chart->Export({
        FileName => "d:\\mychart.gif",
        FilterName => 'GIF',
        Interactive => 0});
$Excel->Quit;
###############################################

                -----Original Message-----
                From:   McManaman, Daniel TQT [mailto:[EMAIL PROTECTED]]
                Sent:   Thursday, March 01, 2001 3:12 PM
                To:     [EMAIL PROTECTED]
                Subject:        Win32::OLE qw(in with) and Excel-->GIF
Questions

                The FAQ has an example "How do I save a chart from Excel as
a
                GIF/JPEG/PNG?".  I can not get this to work.  The FAQ goes
on to say that
                Win32::OLE does not export any variables  and functions to
the namespace, so
                if you want access to the 'in' and 'with' functions, you
should load the
                module as follows (as is in the example):  
                          use Win32::OLE qw(in with);
                This is not a different module than the standard Win32:OLE,
is it?  If it
                is, I can't seem to find it.  Also, any one with experience
saving Excel
                charts as GIFs, are there any hints on making this work?
Does a chart have
                to be saved as either a object or sheet?

                Thank you,
                Dan
                Dallas, TX
                _______________________________________________
                ActivePerl mailing list
                [EMAIL PROTECTED]
                http://listserv.ActiveState.com/mailman/listinfo/activeperl
_______________________________________________
ActivePerl mailing list
[EMAIL PROTECTED]
http://listserv.ActiveState.com/mailman/listinfo/activeperl

Reply via email to