Solved

Trouble in installing Parse::DecDescent module.

Posted on 2006-11-15
3
665 Views
Last Modified: 2012-06-27
Dear Expert,

In  order to use Spreadsheet-WriteExcel, I need to install Parse::DecDescent module. In its readme file, it tells how to install:
---------------------------------------------------------------------------------------
INSTALLATION

    It's all pure Perl, so just put the .pm files in their appropriate
    local Perl subdirectories.
---------------------------------------------------------------------------------------

What is this local Perl subdirectories? I just put DecDescent.pm file in any one of these three directories
\usr\lib\perl5\site_perl\5.8\Spreadsheet\
\usr\lib\perl5\site_perl\5.8\Spreadsheet\WriteExcel
usr\lib\perl5\vendor_perl\5.8\
 it doesn't work for me.

I wrote a test.pl:
#!/usr/bin/perl -w

#use strict;
use Spreadsheet::WriteExcel;

 # Create a new Excel workbook
    my $workbook = Spreadsheet::WriteExcel->new("perl.xls");

    # Add a worksheet
    $worksheet = $workbook->add_worksheet();

    #  Add and define a format
    $format = $workbook->add_format(); # Add a format
    $format->set_bold();
    $format->set_color('red');
    $format->set_align('center');

    # Write a formatted and unformatted string, row and column notation.
    $col = $row = 0;
    $worksheet->write($row, $col, "Hi Excel!", $format);
    $worksheet->write(1,    $col, "Hi Excel!");

    # Write a number and a formula using A1 notation
    $worksheet->write('A3', 1.2345);
    $worksheet->write(3,    $col, "Excel!");
    $worksheet->write('A4', '=SIN(PI()/4)');

When I run test.pl, it always complaints:
The Parse::RecDescent module must be installed in order to write Excel formula.
So it seems that it can not find DecDescent.pm, where should DecDescent.pm be put?

Thanks.
Hanqian  
0
Comment
Question by:Hanqian
  • 2
3 Comments
 
LVL 39

Accepted Solution

by:
Adam314 earned 50 total points
ID: 17948752
\usr\lib\perl5\site_perl\5.8\Parse\RecDescent.pm

0
 

Author Comment

by:Hanqian
ID: 17948875
It works now. Thanks to Adam314.

Hanqian
0
 
LVL 39

Expert Comment

by:Adam314
ID: 17948930
typo: \usr\lib\perl5\site_perl\5.8\Parse\DecDescent.pm
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
perl script 4 108
Using Perl to parse rows 7 96
How to translate this 2-line while loop into C from Perl? 8 97
parse a file and get data out 11 48
On Microsoft Windows, if  when you click or type the name of a .pl file, you get an error "is not recognized as an internal or external command, operable program or batch file", then this means you do not have the .pl file extension associated with …
Email validation in proper way is  very important validation required in any web pages. This code is self explainable except that Regular Expression which I used for pattern matching. I originally published as a thread on my website : http://www…
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…

832 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question