Bug 47876 - Macro error when loading spreadsheet (works in MSoffice)
Summary: Macro error when loading spreadsheet (works in MSoffice)
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: BASIC (show other bugs)
Version:
(earliest affected)
3.5.1 release
Hardware: x86-64 (AMD64) All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: Macro-UI
  Show dependency treegraph
 
Reported: 2012-03-25 19:57 UTC by Chris Martin
Modified: 2019-09-19 12:17 UTC (History)
4 users (show)

See Also:
Crash report or crash signature:


Attachments
Screenshot of errror (152.61 KB, image/png)
2012-03-25 19:57 UTC, Chris Martin
Details
this is a sample spreadsheet that exibits the same problem. (813.42 KB, application/vnd.ms-excel.sheet.macroEnabled.12)
2012-06-22 06:45 UTC, Chris Martin
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Chris Martin 2012-03-25 19:57:05 UTC
Created attachment 59044 [details]
Screenshot of errror

I have a spread sheet that contains macros.
This spreadsheet work will in Ms-office 2003, 2007 and 2010
I have tried in on libreoffice on both Ubuntu 12.04 and Windows 7, both running libreoffice 3.5.1.
I get the same error in both. It is 100% reproducible.


   BASIC runtime error.

   '1'

   Type: com.sun.star.lang.illegalArgumentException

   Message:


Attached is a screenshot of the error and the offending line

I have not attached the spreadsheet, as it has some confidential information, however I will make it available to anyone working on the bug with the understanding that it will not be attached to a public bug report.
Comment 1 sasha.libreoffice 2012-06-19 02:51:12 UTC
Thanks for bugreport
What if copy-paste only this Basic function to another spreadsheet? May be produced spreadsheet will also demonstrate this bug, but will be possible to attach it here.
Comment 2 Chris Martin 2012-06-22 06:45:15 UTC
Created attachment 63342 [details]
this is a sample spreadsheet that exibits the same problem.

this is a sample spreadsheet that exibits the same problem.  It is the same spreadsheet that generated the original issue, but I now have access to a copy of excel 2007 and have been able to remove the confidential information.

NOTE: there are other bugs that the spreadsheet exhibits.
Saving from calc will cause it to crash.
Deleting a worksheet will cause a crash.
Comment 3 sasha.libreoffice 2012-06-26 01:59:17 UTC
Thanks for attachment
reproduced in 3.3.4, 3.5.4 and 3.6.beta1 on Fedora 64 bit

msExcel 2007 outputs this message: Run-time error '1004': Wrong password

As I can see, problem of Calc with this attachment is not that macro not works, but that error message is empty. Impossible to understand it.
Comment 4 sasha.libreoffice 2012-06-26 02:01:07 UTC
@ Noel
Greetings
What do You think about this bug?
Comment 5 Noel Power 2012-06-26 03:55:12 UTC
(In reply to comment #3)
> Thanks for attachment
> reproduced in 3.3.4, 3.5.4 and 3.6.beta1 on Fedora 64 bit
> 
> msExcel 2007 outputs this message: Run-time error '1004': Wrong password
> 
> As I can see, problem of Calc with this attachment is not that macro not works,
> but that error message is empty. Impossible to understand it.

well, this is the same error the underlying libreoffice api gives back, sure... could be a better message. That's an enhancement at best ( and should be an easy hack imho )

more worrying is that it seems the xls[x|m] import doesn't import the protection passwords, don't know why that is, perhaps that information is in an unpublished format ?, I have no idea, but.. looking at the code I can see that a password is not set ( protection *is* set, but with a blank password ). 
IMHO that is worth a bug
Comment 6 QA Administrators 2015-04-19 03:21:40 UTC Comment hidden (obsolete)
Comment 7 Buovjaga 2015-06-16 17:06:13 UTC
(In reply to Noel Power from comment #5)
> more worrying is that it seems the xls[x|m] import doesn't import the
> protection passwords, don't know why that is, perhaps that information is in
> an unpublished format ?, I have no idea, but.. looking at the code I can see
> that a password is not set ( protection *is* set, but with a blank password
> ). 
> IMHO that is worth a bug

Seems to still be true.

No macro errors on loading.

Saving or deleting sheet didn't crash.

Win 7 Pro 64-bit Version: 5.1.0.0.alpha1+
Build ID: 80ec99db4325a439a8a3f1d420d0a80f8bf9c439
TinderBox: Win-x86@62-merge-TDF, Branch:MASTER, Time: 2015-06-16_00:00:20
Locale: fi-FI (fi_FI)
Comment 8 QA Administrators 2016-09-20 10:02:24 UTC Comment hidden (obsolete)
Comment 9 Buovjaga 2019-08-11 10:26:09 UTC
Still confirmed with file

Arch Linux 64-bit
Version: 6.4.0.0.alpha0+
Build ID: 37fc9f51a8de11d40632e8cda17ccf1fa4b1f503
CPU threads: 8; OS: Linux 5.2; UI render: default; VCL: gtk3; 
Locale: fi-FI (fi_FI.UTF-8); UI-Language: en-US
Calc: threaded
Built on 6 August 2019