[Libreoffice-bugs] [Bug 114676] New: Base Freezes on DB Connect() macro

bugzilla-daemon at bugs.documentfoundation.org bugzilla-daemon at bugs.documentfoundation.org
Sun Dec 24 01:08:51 UTC 2017


https://bugs.documentfoundation.org/show_bug.cgi?id=114676

            Bug ID: 114676
           Summary: Base Freezes on DB Connect() macro
           Product: LibreOffice
           Version: 6.0.0.1 rc
          Hardware: x86-64 (AMD64)
                OS: Linux (All)
            Status: UNCONFIRMED
          Severity: normal
          Priority: medium
         Component: Base
          Assignee: libreoffice-bugs at lists.freedesktop.org
          Reporter: sgrekow at yahoo.com

Description:
This does work on:

Version: 5.4.3.2
Build ID: 92a7159f7e4af62137622921e809f8546db437e5
CPU threads: 4; OS: Linux 4.8; UI render: default; VCL: gtk2; 
Locale: en-US (en_US.UTF-8); Calc: group

and previous versions using a variety of databases (split, PostGreSQL, MySQL,
MariaDB).

This will not work in:

Version: 6.0.0.1
Build ID: d2bec56d7865f05a1003dc88449f2b0fdd85309a
CPU threads: 4; OS: Linux 4.8; UI render: default; VCL: gtk2; 
Locale: en-US (en_US.UTF-8); Calc: group


This problem only occurs under specific conditions.


Steps to Reproduce:
Testing:

Using LO v5.4.3.2 (or prior) opening the Base file asks for a PW (click OK -
none needed) then opens a form.  This is what should happen.

Using LO v6.0.0.1 with same Base file just locks up.  Notice there isn't even a
menu bar displayed.  Only way to is to click upper right 'x', wait, then click
force quit.  Only recovery is to open with v5.4.3.2 or older to recover.

Some points worthy of notice.  With PW required turned OFF the split file works
in v6.0 (haven't tested others as pain setting up various user PW scenarios;
also not typical to require no password).  Also, with the two lines noted above
commented out, all work OK in v6.0 (various DB's)


Actual Results:  
Base file just locks up.  Notice there isn't even a menu bar displayed.  Only
way to is to click upper right 'x', wait, then click force quit.  Only recovery
is to open with v5.4.3.2 or older to recover.
So it appears there is a timing problem with signing in and executing
"ThisDataBaseDocument.CurrentController.Connect()".


Expected Results:
The objective is to open a specific form when starting the Base file.



Reproducible: Always


User Profile Reset: No



Additional Info:
The following macro is attached to the "Open Document" of the .odb (in
Standard->Module1):

SUB OpeningForm
  Dim ObjTypeWhat
  Dim ObjName As String
  Setup  
  ObjName = "MultiForm"
  ObjTypeWhat = com.sun.star.sdb.application.DatabaseObject.FORM
  If ThisDatabaseDocument.FormDocuments.hasbyname(ObjName) Then 'Check the form
exists'
     ThisDataBaseDocument.CurrentController.Connect() 'If the form exists
connect to the database'
     ThisDatabaseDocument.CurrentController.loadComponent(ObjTypeWhat, ObjName,
FALSE) 'Open the form'
  Else
      MsgBox "Error! Wrong form name used. " & ObjName
  End if
End Sub


These are the problem lines:
     ThisDataBaseDocument.CurrentController.Connect() 'If the form exists
connect to the database'
     ThisDatabaseDocument.CurrentController.loadComponent(ObjTypeWhat, ObjName,
FALSE) 'Open the form'


Attached is a sample (zipped split Base HSQL DB) where "Password Required" is
set ON.  There is no password involved but this is when the problem happens. 
By the way, the only way to turn this off now is by editing the 'content.xml'
file in the .odb root - See Bug #97416.



User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like
Gecko) Chrome/63.0.3239.108 Safari/537.36

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/libreoffice-bugs/attachments/20171224/636999b8/attachment.html>


More information about the Libreoffice-bugs mailing list