Description: I had some (simplified below) VBA code in C:\Users\<user>\AppData\Roaming\LibreOffice\4\user\SafeMode\basic\Standard\Module1.xba Sub testMsgBox() Dim sVar As Integer #sVar = MsgBox("test") End Sub In the version 24.2.2.2 this wasn't causing any issues. I assumed the line beginning with the # character was being ignored/ commented out. When I installed 24.8.0.3_Win_x86-64.msi today, opening any LibreOffice Writer or Calc file would immediately crash with the VBA editor/ IDE displaying the above line. It appears to be the hash character is no longer interpreted as a comment, if it ever was. After a long period of trial & error, I finally found that replacing the # with ' fixed the problem. Steps to Reproduce: 1.Tools > Macros > Edit > add a subroutine Sub testMsgBox() Dim sVar As Integer #sVar = MsgBox("test") End Sub 2. close program & restart 3. observe crash Actual Results: crash with VBA stuck on line beginning with hash character Expected Results: the program should open without error Reproducible: Always User Profile Reset: No Additional Info: no other info - make this textbox optional?
Created attachment 195975 [details] screen cap when Writer opened
I wonder, if this could be related to bug 93727. I tried to reproduce the issue, but I didn't get any crash. Do you also see the crash with a daily build? https://dev-builds.libreoffice.org/daily/master/current.html Could you give exact steps to follow on how we should create the macro and where exactly? I first tried in a document and then in My Macros. But you talk about VBA code, so maybe there is some information missing? You might also try bibisecting this: https://wiki.documentfoundation.org/QA/Bibisect/Windows You could make it quicker by trying first in the 24.8 Windows repo git checkout fdae99a7b9e530a48d2383a6ee696115a1be79ec && instdir/program/soffice and then test - does it crash? If yes, then: git checkout HEAD~1 && instdir/program/soffice and test again - now you are testing the immediately preceding commit. If it doesn't crash here, then the culprit is the change of bug 93727. Otherwise you have to do the full bibisecting procedure. Arch Linux 64-bit Version: 25.2.0.0.alpha0+ (X86_64) / LibreOffice Community Build ID: 05dafbdc9d7e6755d67d63e58cec3cc1f9038848 CPU threads: 8; OS: Linux 6.11; UI render: default; VCL: kf6 (cairo+wayland) Locale: fi-FI (fi_FI.UTF-8); UI: en-US Calc: CL threaded Built on 7 November 2024
Wow - that's a lot of research. It'll take me a while to work thru those suggestions, so bear with me.
[Automated Action] NeedInfo-To-Unconfirmed
tested in 24.8.4.2 & can no longer reproduce, so updated status