Skip Menu |
 

This queue is for tickets about the Spreadsheet-WriteExcel CPAN distribution.

Maintainer(s)' notes

If you are reporting a bug in Spreadsheet::WriteExcel here are some pointers

1) State the issues as clearly and as concisely as possible. A simple program or Excel test file (see below) will often explain the issue better than a lot of text.

2) Provide information on your system, version of perl and module versions. The following program will generate everything that is required. Put this information in your bug report.

    #!/usr/bin/perl -w

    print "\n    Perl version   : $]";
    print "\n    OS name        : $^O";
    print "\n    Module versions: (not all are required)\n";

    my @modules = qw(
                      Spreadsheet::WriteExcel
                      Parse::RecDescent
                      File::Temp
                      OLE::Storage_Lite
                      IO::Stringy
                      Spreadsheet::ParseExcel
                      Scalar::Util
                      Unicode::Map
                    );

    for my $module (@modules) {
        my $version;
        eval "require $module";

        if (not $@) {
            $version = $module->VERSION;
            $version = '(unknown)' if not defined $version;
        }
        else {
            $version = '(not installed)';
        }

        printf "%21s%-24s\t%s\n", "", $module, $version;
    }

    __END__

3) Upgrade to the latest version of Spreadsheet::WriteExcel (or at least test on a system with an upgraded version). The issue you are reporting may already have been fixed.

4) Create a small but complete example program that demonstrates your problem. The program should be as small as possible. At the same time it should be a complete program that generates an Excel file. If the Spreadsheet::WriteExcel section is part of a much larger program then simplify it down to the essentials. Simulate any DB reads with an array.

5) Say if you tested with Excel, OpenOffice, Gnumeric or something else. Say which version of that application you used.

6) If you are submitting a patch you should check with the author whether the issue has already been patched or if a fix is in the works. Patches should be accompanied by test cases.

Asking a question

If you would like to ask a more general question there is the Spreadsheet::WriteExcel Google Group.

Report information
The Basics
Id: 38099
Status: resolved
Priority: 0/
Queue: Spreadsheet-WriteExcel

People
Owner: Nobody in particular
Requestors: ThomasKratz [...] web.de
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: strange name conflict with autofilter
Date: Fri, 01 Aug 2008 15:33:11 +0200
To: bug-Spreadsheet-WriteExcel [...] rt.cpan.org
From: Thomas Kratz <ThomasKratz [...] web.de>
Download (untitled) / with headers
text/plain 866b
Hi, the below test script produces an xls file that comes up with a dialog directly after opening, saying that there is a name conflict with '_FilterDatenbank' (German Excel 2000). Just by exchanging the two 'add_worksheet' lines, the problem disappears. use strict; use warnings; use Spreadsheet::WriteExcel; my $wb = Spreadsheet::WriteExcel->new('test.xls'); # swap the following two lines for the error to disappear my $a_ws = $wb->add_worksheet('S'); my $b_ws = $wb->add_worksheet('A'); $a_ws->autofilter(0, 0, 1, 1); $b_ws->autofilter(0, 0, 1, 1); $wb->close(); perl v5.8.8 built for MSWin32-x86-multi-thread Spreadsheet-WriteExcel-2.22 Thomas Show quoted text
_____________________________________________________________________ Der WEB.DE SmartSurfer hilft bis zu 70% Ihrer Onlinekosten zu sparen! http://smartsurfer.web.de/?mc=100071&distributionid=000000000066
Download (untitled) / with headers
text/plain 445b
On Fri Aug 01 09:33:31 2008, ThomasKratz@web.de wrote: Show quoted text
> the below test script produces an xls file that comes up with a dialog > directly after opening, saying that there is a name conflict with > '_FilterDatenbank' (German Excel 2000).
Hi Thomas, I don't have Excel 2000 and I cannot reproduce it with English Excel 97 or 2003. I do believe you that it exists though. :-) I have an idea what might cause it. I'll look into it. John. --
Hi Thomas, I still haven't been able to reproduce this or find the cause. If you have a little time perhaps you could help me debug it. Could you do the following (the open and close parts are important). 1. Open Excel. 2. Select "Tools -> Options -> General -> Sheets in new Workbook" 3. Set it to 2 or more. 4. Close Excel. 5. Open Excel. 6. Paste or add the following data into the first 2 worksheets. a b c 1 1 1 2 2 2 3 3 3 4 4 4 7. Select cell A1 on Sheet 1. 8. Save the workbook as rt01.xls. 9. On Sheet1 select the area A1:C5 and set the autofilter. 10. Select cell A1. 11. On Sheet2 select the area A1:C5 and set the autofilter. 12. Select cell A1. 13. Select cell A1 on Sheet 1. 14. Save the workbook as rt02.xls. 15. Close Excel. 16. Open Excel. 17. Reopen rt01.xls. 18. On Sheet2 select the area A1:C5 and set the autofilter. 19. Select cell A1. 20. On Sheet1 select the area A1:C5 and set the autofilter. 21. Select cell A1. 22. Save the workbook as rt03.xls. Zip up the rt01.xls, rt02.xls and rt03.xls files and send them to me. Thanks, John. --
Download (untitled) / with headers
text/plain 102b
P.S. Send the files to the address in the docs. No point clogging up the system here. :-) John. --
Download (untitled) / with headers
text/plain 898b
Le Ven. Aoû. 01 09:33:31 2008, ThomasKratz@web.de a écrit : Show quoted text
> Hi, > > the below test script produces an xls file that comes up with a dialog > directly after opening, saying that there is a name conflict with > '_FilterDatenbank' (German Excel 2000).
Hi, I juste encountered a similar problem (French Excel 2003). First version of my script created a workbook with several worksheets and autofilter in each of them; when opening the file, Excel reports a name conflict in the first sheet on "_FilterDatabase". In a second version of the script, I added printing instructions by calling $worksheet->repeat_rows(..) and $worksheet->repeat_columns(..). Surprisingly, this caused the problem with _FilterDatabase to disappear, but now there is a name conflict on "Impression_des_titres". I'll try to isolate the problem in a shorter script and post it a bit later. Best regards, Laurent Dami
Download (untitled) / with headers
text/plain 336b
Here is a script that demonstrates the name conflict. The bug is related to the number of sheets (starts with 10 sheets or more). It is not related specifically to autofilter(), but rather to builtin internal names used by Excel; so we get the same bug when calling repeat_rows() instead of autofilter(). Best regards, Laurent Dami
Download name_conflict.pl
text/x-perl 905b
# laurent.dami@justice.ge.ch, July 09. # script to demonstrate bug with autofilter() or repeat_rows(). use strict; use warnings; use Spreadsheet::WriteExcel; my $n_sheets = $ARGV[0] || 10; my $xls_name = "foo.xls"; my @data = ([qw/FOO BAR/], [1, 2], [qw/a b/]); my $workbook = Spreadsheet::WriteExcel->new("$xls_name") or die "could not create workbook $xls_name, $!"; for my $i (1 .. $n_sheets) { my $worksheet = $workbook->add_worksheet("Tst $i"); $worksheet->write($_, 0, $data[$_]) foreach 0 .. $#data; # with 10 sheets or more, either 'repeat_rows' or 'autofilter' will # create a name conflict when opening the file in Excel (but both # conflicts do not cumulate; one shadows the other). $worksheet->repeat_rows(0); $worksheet->autofilter(0, 0, @data -1 , @{$data[0]}-1); } $workbook->close(); # open in Excel (assuming we are on a Win32 system) system ("start $xls_name");
Download (untitled) / with headers
text/plain 814b
On Mon Jul 27 04:48:12 2009, DAMI wrote: Show quoted text
> Here is a script that demonstrates the name conflict. > > The bug is related to the number of sheets (starts with 10 sheets or
more). Show quoted text
> > It is not related specifically to autofilter(), but rather to builtin > internal names used by Excel; so we get the same bug when calling > repeat_rows() instead of autofilter(). > > Best regards, Laurent Dami >
Hi, I identified a fix for this even if I didn't figure out what was causing it exactly. Could you try the following test release: http://homepage.eircom.net/~jmcnamara/perl/prerel/Spreadsheet-WriteExcel-2.25.07.tar.gz And somewhere in your program set the country code for France using the new set_country() workbook method: $workbook->set_country(33); Let me know if that fixes the problem. John. --
Download (untitled) / with headers
text/plain 545b
Le Mer. Jul. 29 12:01:03 2009, JMCNAMARA a écrit : Show quoted text
> > Hi, > > I identified a fix for this even if I didn't figure out what was > causing > it exactly. > > Could you try the following test release: > > http://homepage.eircom.net/~jmcnamara/perl/prerel/Spreadsheet- > WriteExcel-2.25.07.tar.gz > > And somewhere in your program set the country code for France using > the > new set_country() workbook method: > > $workbook->set_country(33); > > Let me know if that fixes the problem. > > John.
YES, it works. Great, thanks! Laurent D.
Subject: next public release ?
Download (untitled) / with headers
text/plain 787b
Hi John, Since your dev. version 2.25.07 solved the bug, could you please make it an official release ? Thanks in advance, Laurent Dami Le Jeu. Jul. 30 08:41:48 2009, DAMI a écrit : Show quoted text
> Le Mer. Jul. 29 12:01:03 2009, JMCNAMARA a écrit :
> > > > Hi, > > > > I identified a fix for this even if I didn't figure out what was > > causing > > it exactly. > > > > Could you try the following test release: > > > > http://homepage.eircom.net/~jmcnamara/perl/prerel/Spreadsheet- > > WriteExcel-2.25.07.tar.gz > > > > And somewhere in your program set the country code for France using > > the > > new set_country() workbook method: > > > > $workbook->set_country(33); > > > > Let me know if that fixes the problem. > > > > John.
> > YES, it works. Great, thanks! > > Laurent D.
Download (untitled) / with headers
text/plain 213b
On Mon Nov 02 02:43:42 2009, DAMI wrote: Show quoted text
> Hi John, > > Since your dev. version 2.25.07 solved the bug, could you please make it > an official release ?
Hi, This fix has gone into the 2.26 release. John. --
Download (untitled) / with headers
text/plain 301b
Le Sam. Nov. 14 08:09:44 2009, JMCNAMARA a écrit : Show quoted text
> On Mon Nov 02 02:43:42 2009, DAMI wrote:
> > Hi John, > > > > Since your dev. version 2.25.07 solved the bug, could you please make it > > an official release ?
> > Hi, > > This fix has gone into the 2.26 release. > > John.
Perfect, thanks.
Download (untitled) / with headers
text/plain 635b
On Fri Aug 01 09:33:31 2008, ThomasKratz@web.de wrote: Show quoted text
> Hi, > > the below test script produces an xls file that comes up with a dialog > directly after opening, saying that there is a name conflict with > '_FilterDatenbank' (German Excel 2000). Just by exchanging the two > 'add_worksheet' lines, the problem disappears.
Hi, This issue should be fixed in Spreadsheet::WriteExcel 2.36. Note, the fix doesn't require the set_country() workaround and for compatibility with other versions of Excel you probably should use it. If you get a chance to test it you can let me know how it works out. Thanks for your input. John. --


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.