Created attachment 179584 [details] .ods file to reproduce the problem Steps to reproduce: - open the attached .ods file - edit macros - go to macro "test_bug" and execute => the macro does nothing - now remove all other macros in the module - execute again "test_bug" => the macro now produces something Do I miss something obvious or is this a bug?
Note that in the test_bug macro, if I write: sheets("Feuil1").cells(2,1) = "test" it works. So LO is able to write something, but not to read.
Created attachment 179588 [details] Minimal bugdoc Repro using Version: 7.3.3.1 (x64) / LibreOffice Community Build ID: 1688991ca59a3ca1c74bc2176b274fba1b034928 CPU threads: 12; OS: Windows 10.0 Build 19044; UI render: default; VCL: win Locale: ru-RU (ru_RU); UI: en-US Calc: The attachment has minimal macro needed to reproduce the bug. Looks like having something named "cells" referenced from a sub, affects use of an object's member having the same name in another function. Renaming "cells" to anything else in "test3" makes "test_bug" function properly copy data from A1 to A2.
A workaround to this problem is to copy "test_bug" to another module and execute it from there.
This bug is still present in 7.5.9.
Still present in 24.8.3.2.