STEPS TO REPRODUCE: 1. Run the following code REM ***** BASIC ***** Option Explicit Sub Main() StarDesktop.getPropertySetInfo().getProperties() End Sub ACTUAL RESULT: crash EXPECTED RESULT: no crash ENVIRONMENT: Version: 5.0.1.2 (x64) Build ID: 81898c9f5c0d43f3473ba111d7b351050be20261 Locale: ja-JP (ja_JP) OS: Windows 10
Hi, Thanks for filing the issue! What you see is due to a api-change Please try the following: If HasUnoInterfaces(ThisComponent, "com.sun.star.document.XDocumentInfoSupplier") Then ' 3.x oDocInfo = ThisComponent.getDocumentInfo() oDocSetInfo = oDocInfo.getPropertySetInfo Else oDocSetInfo = ThisComponent.getDocumentProperties.getUserDefinedProperties.getPropertySetInfo oDocInfo = ThisComponent.getDocumentProperties.getUserDefinedProperties End If If oDocSetInfo.hasPropertyByName(sName) Then ReadMyDocProp = oDocInfo.getPropertyValue(sName) End If Cheers, Cor
Thanks for the comment. but actually I did not intend to get document properties or to write meaningful code, but was trying to find a line of code that crashes LibreOffice. I still believe we should not leave the crash as is. at least the StarBasic should be changed so that it gives a runtime error. reopening this bug.
Thanks for reopening! I had a little doubt already when commenting. Sorry for not understanding you well enough. I cannot reproduce the crash on Linux 32 bits. (But it's not exceptional that something crashes on one platform and returns an error on the other, see e.g. tdf#92446)
Doesn't crash here.. I have 32-bit build, though. Win 7 Pro 64-bit, Version: 5.0.1.2 (32-bit) Build ID: 81898c9f5c0d43f3473ba111d7b351050be20261 Locale: fi-FI (fi_FI)
No crash with Version: 5.1.0.0.alpha1+ (x64) Build ID: bf2116353a89c402bf19b79d49eadf4454103423 TinderBox: Win-x86_64@62-TDF, Branch:MASTER, Time: 2015-09-16_11:35:23
Hi, I see three WorksForMe. So safe to close and assume something else gives a problem? Cheers - Cor