Issue 94980 - error using LoadDialog from "Tools" Library
Summary: error using LoadDialog from "Tools" Library
Alias: None
Product: App Dev
Classification: Unclassified
Component: scripting (show other issues)
Version: 3.3.0 or older (OOo)
Hardware: Unknown All
: P2 Trivial
Target Milestone: ---
Assignee: joerg.skottke
QA Contact: Unknown
Keywords: regression
Depends on:
Blocks: 93339
  Show dependency tree
Reported: 2008-10-16 09:13 UTC by Oliver Brinzing
Modified: 2013-02-24 21:01 UTC (History)
5 users (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: ---
Developer Difficulty: ---

loadlibrary bug (8.41 KB, application/vnd.sun.xml.calc)
2008-10-16 09:14 UTC, Oliver Brinzing
no flags Details

Note You need to log in before you can comment on or make changes to this issue.
Description Oliver Brinzing 2008-10-16 09:13:37 UTC

i noticed a bug in OO 3.0 final:

Executing a dialog using LoadLibrary() will end in an error.
Dialog is opened, but can't be closed with 'ok' button.

Closing dialog with "X" will display an error message.

Copying the LoadLibrary() code to the document's basic library
will not cause the error ...

OO 1.1.5 and OO 2.4.1 are not affected at all.

I will send an attachment.


REM  *****  BASIC  *****
Option Explicit

Dim oDlg as Object

Sub Main
	oDlg = LoadDialog("Standard", "Dialog1", DialogLibraries)
End Sub

Sub click_ok
	MsgBox "ok clicked ..."
End Sub
Comment 1 Oliver Brinzing 2008-10-16 09:14:37 UTC
Created attachment 57153 [details]
loadlibrary bug
Comment 2 Oliver Brinzing 2008-10-16 09:28:10 UTC
it is of course LoadDialog() ...
Comment 3 cno 2008-10-21 18:28:14 UTC
I can confirm this error.
The code/dialog combination does work when placed in a global library.

Also ... this works from the document macro container without error:
	'oDlg = LoadDialog("Standard", "Dialog1", DialogLibraries)
	oDlg =  CreateUnoDialog(DialogLibraries.Standard.Dialog1)

Can you pls test that?
Comment 4 drewjensen.inbox 2008-10-21 21:03:05 UTC
Executed the macro in the test document using 3.0 Final under Ubuntu 8.04.

It appears to me that the problem is not with LoadDialog at all - rather it is
with the syntax used for 'When initializing' event on the button control.

In the test document the old style naming convention is used:

if I replace this with the new style:

then everything works as one would expect under 3.0

I then tried the bug doc (the old naming) using the Ubuntu supplied OOo 2.4.1
and also experienced the problems you describe here - but again, a change to the
new naming convention puts everything right, with 2.4.1.

Comment 5 Oliver Brinzing 2008-10-22 17:00:40 UTC
> I then tried the bug doc (the old naming) using the Ubuntu 
> supplied OOo 2.4.1 and also experienced the problems you describe
> here - but again, a change to the
>new naming convention puts everything right, with 2.4.1.

i just tried with OO 2.4.1 on XP and Vista, and have no problems with the
attached *.sxw ...
Comment 6 Frank Schönheit 2008-10-27 10:21:36 UTC
fs->ab: Seems to be a problem with BasicScriptListener_Impl::firing_impl not
finding the document's StarBASIC instance.

Nominating as stopper issue for 3.0.1, adding "regression" keyword.
Comment 7 joerg.skottke 2008-10-28 11:49:19 UTC
CC me, to me for verification when fixed.
Comment 8 ab 2008-10-31 13:32:24 UTC
Comment 9 ab 2008-10-31 16:38:18 UTC
ab->jsk: Please verify
Comment 10 joerg.skottke 2008-11-04 12:37:07 UTC
Comment 11 Oliver Brinzing 2008-11-14 17:04:45 UTC
can one please give me a hint which dev  build will contain the bugfix ?
Comment 12 rene 2008-11-27 09:15:15 UTC
brinzing: OOO300_m12
Comment 13 Oliver Brinzing 2008-11-28 18:07:24 UTC
fixed - can confirm
also fixed in ooodev31 m36  :-)
Comment 14 joerg.skottke 2008-12-08 13:09:20 UTC
Closing, thanks for the help.