Access2Base - Avoid use of outdated routines
in getObject, getValue and setValue functions Change-Id: I98ff54bf62cfb34218d1fdb43fb37ba21846b068
This commit is contained in:
@@ -461,7 +461,7 @@ Dim oDoc As Object
|
||||
Case OBJFORM, OBJSUBFORM, OBJCONTROL, OBJDIALOG
|
||||
vCurrentObject = vCurrentObject.Controls(sComponents(iCurrentIndex))
|
||||
End Select
|
||||
If sCurrentProperty <> "" Then vCurrentObject = PropertiesGet._getProperty(vCurrentObject, sCurrentProperty)
|
||||
If sCurrentProperty <> "" Then vCurrentObject = vCurrentObject.getProperty(sCurrentProperty)
|
||||
Next iCurrentIndex
|
||||
|
||||
Set getObject = vCurrentObject
|
||||
@@ -714,10 +714,11 @@ Dim vItem As Variant, sProperty As String
|
||||
Set vItem = getObject(pvObject)
|
||||
sProperty = Utils._FinalProperty(pvObject)
|
||||
If sProperty = "" Then sProperty = "Value" ' Default value if final property in shortcut is absent
|
||||
getValue = PropertiesGet._getProperty(vItem, sProperty)
|
||||
getValue = vItem.getProperty(sproperty)
|
||||
Utils._ResetCalledSub("getValue")
|
||||
Else
|
||||
getValue = PropertiesGet._getProperty(pvObject, "Value")
|
||||
Set vItem = pvObject
|
||||
getValue = vItem.getProperty("Value")
|
||||
End If
|
||||
End Function ' getValue
|
||||
|
||||
|
@@ -334,13 +334,14 @@ Dim vItem As Variant, sProperty As String
|
||||
If IsMissing(pvObject) Or IsMissing(pvValue) Or IsEmpty(pvObject) Then Call _TraceArguments("setValue")
|
||||
If VarType(pvObject) = vbString Then
|
||||
Utils._SetCalledSub("setValue")
|
||||
vItem = getObject(pvObject)
|
||||
Set vItem = getObject(pvObject)
|
||||
sProperty = Utils._FinalProperty(pvObject)
|
||||
If sProperty = "" Then sProperty = "Value"
|
||||
setValue = PropertiesSet._setProperty(vItem, sProperty, pvValue)
|
||||
setValue = vItem.setProperty(sProperty, pvValue)
|
||||
Utils._ResetCalledSub("setValue")
|
||||
Else
|
||||
setValue = PropertiesSet._setProperty(pvObject, "Value", pvValue)
|
||||
Set vItem = pvObject
|
||||
setValue = vItem.setProperty("Value", pvValue)
|
||||
End If
|
||||
End Function ' setValue
|
||||
|
||||
|
Reference in New Issue
Block a user