Apache OpenOffice (AOO) Bugzilla – Issue 107263
Wrong constructor used for new-style services in Basic
Last modified: 2017-05-20 10:29:02 UTC
When calling a new-style service constructor in Basic, the name of the constructor is ignored and the last defined constructor is used (SbUnoService::Find). The following example gives an error because createKnown is called instead of create. Sub Main UriService = com.sun.star.rdf.URI oSubject = UriService.create("http://hallo/hallo") print oSubject.StringValue End Sub
STARTED
adjusted target
Fixed in basic/source/classes/sbunoobj.cxx Extended test macro using all three ctors: Sub Main UriService = com.sun.star.rdf.URI oSubject = UriService.create("http://hallo/hallo") print oSubject.StringValue oSubjectNS = UriService.createNS("ftp:","//foo/bar") print oSubjectNS.StringValue oSubjectKnown = UriService.createKnown(com.sun.star.rdf.URIs.XSD_DECIMAL) print oSubjectKnown.StringValue End Sub
cd->ab: Please send issue to QA or verify yourself.
ab->tm: Please verify. To to this you just need to open the Basic IDE (Tools / Macros / Organize Macros / Basic... or simple Alt-F11 + Edit) and copy the test macro above into a module. It should run (F5) without errors showing the expected results.
checked and verified in cws fwk131 -> OK !