in reply to Re^4: which module to use?
in thread which module to use?

As you already have the Visual Basic code, it's easy to translate that into Perl, if your code runs on Windows and you have the module Win32::OLE. Win32::OLE does (quite unsurprisingly) not work on operating systems that are not Windows.

  1. Start in small steps, don't translate all of the file at once
  2. At the top add the code to get an Excel instance (see Win32::OLE)
  3. Import the correct type library (using Win32::OLE::Const) or find the numeric values of all constants using Google
  4. Prefix $excel-> in front of every statement
  5. Replace every dot in VB with the arrow: s/\./->/g
  6. With ... .LineStyle = xlContinuous ...
    becomes
    my $foo = ...; $foo->LineStyle = xlContinous;

Also see Using Win32::OLE and Excel - Tips and Tricks, Scripting data extraction from excel files in a directory. and the nodes I linked from there