From a2a627a6d4e420d83d2aff533d6ef3b73ec74710 Mon Sep 17 00:00:00 2001 From: Jean-Pierre Ledure Date: Wed, 9 Oct 2019 12:55:09 +0200 Subject: Access2Base - Support dialogs owned by non-Base docs So far, AllDialogs found only dialogs stored in Base (.odb) documents. From now on, dialogs in ThisComponent atr considered as well. Change-Id: I4977b09140c673ad7aca379c1a67a2d731384782 --- wizards/source/access2base/Application.xba | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/wizards/source/access2base/Application.xba b/wizards/source/access2base/Application.xba index f821cf270519..3bc2837aac2a 100644 --- a/wizards/source/access2base/Application.xba +++ b/wizards/source/access2base/Application.xba @@ -217,15 +217,20 @@ Const cstSepar = "!" Set vAllDialogs = Nothing - Set vCurrentDocument = _A2B_.CurrentDocument + Set vCurrentDocument = Nothing + If Not IsNull(_A2B_.CurrentDocument) Then + Set vCurrentDocument = _A2B_.CurrentDocument.Document + ElseIf Not IsNull(ThisComponent) Then + Set vCurrentDocument = ThisComponent + End If If IsNull(vCurrentDocument) Then Set oDocLibraries = Nothing vDocLibraries = Array() Else - Set oDocLibraries = _A2B_.CurrentDocument.Document.DialogLibraries ' ThisComponent.DialogLibraries + Set oDocLibraries = vCurrentDocument.DialogLibraries vDocLibraries = oDocLibraries.getElementNames() End If - Set oMacLibraries = DialogLibraries + Set oMacLibraries = GlobalScope.DialogLibraries vMacLibraries = oMacLibraries.getElementNames() 'Remove Access2Base from the list If _A2B_.ExcludeA2B Then -- cgit