https://bugs.documentfoundation.org/show_bug.cgi?id=79588
--- Comment #29 from Mike Kaganski <[email protected]> --- (In reply to Eike Rathke from comment #5) > I don't know why, but moving the getrowofcursor() function from BASIC module > Wodi/Kassenbericht to module Standard/Kassenberichte helps. Somehow the > function is not found in the Wodi module after the document is opened, but > is found after having opened the Basic manager once. FTR: only libraries named "Standard" and "VBAProject" are loaded automatically in BasicManager::SetLibraryContainerInfo (basic/source/basmgr/basmgr.cxx). This method is called both for application BASIC, and for document BASIC, so only functions available in these libraries are available for execution until other libraries are loaded. Since function resolution is performed before the security prompt, it's impossible to use any Basic code to load other libraries here (the resolution of all formulas happens in ScCompiler::ParseMacro during the load, then macro execution is performed in ScInterpreter::ScMacro, at which point the prompt is shown, and only then programmatic loading of other libraries could happen, but the compiler has already rejected the names from not-yet-loaded libraries as unknown at this point). Possibly this should be a documentation issue, or *possibly* ScCompiler::ParseMacro could try loading other libraries after it failed to find the name ... but I don't know how much impact could that be. -- You are receiving this mail because: You are the assignee for the bug.
