summaryrefslogtreecommitdiff
path: root/wizards/source/access2base/SubForm.xba
diff options
context:
space:
mode:
Diffstat (limited to 'wizards/source/access2base/SubForm.xba')
-rw-r--r--wizards/source/access2base/SubForm.xba5
1 files changed, 4 insertions, 1 deletions
diff --git a/wizards/source/access2base/SubForm.xba b/wizards/source/access2base/SubForm.xba
index 30add0f38a09..d905a9836058 100644
--- a/wizards/source/access2base/SubForm.xba
+++ b/wizards/source/access2base/SubForm.xba
@@ -17,6 +17,7 @@ REM ----------------------------------------------------------------------------
Private _Type As String ' Must be SUBFORM
Private _This As Object ' Workaround for absence of This builtin function
+Private _Parent As Object
Private _Shortcut As String
Private _Name As String
Private _MainForm As String
@@ -32,6 +33,7 @@ REM ----------------------------------------------------------------------------
Private Sub Class_Initialize()
_Type = OBJSUBFORM
Set _This = Nothing
+ Set _Parent = Nothing
_Shortcut = ""
_Name = ""
_MainForm = ""
@@ -317,7 +319,7 @@ Public Function Parent() As Object
Utils._SetCalledSub("SubForm.getParent")
On Error Goto Error_Function
- Set Parent = PropertiesGet._ParentObject(_Shortcut)
+ Set Parent = _Parent
Exit_Function:
Utils._ResetCalledSub("SubForm.getParent")
@@ -395,6 +397,7 @@ Dim j As Integer
' Determine exact name
Set ocControl = New Control
Set ocControl._This = ocControl
+ Set ocControl._Parent = _This
ocControl._ParentType = CTLPARENTISSUBFORM
sParentShortcut = _Shortcut
sControls() = DatabaseForm.getElementNames()