'/** ' * Ă„ndert ein DB-Property ' * @param String Name des Property ' * @param Variant Type des Property ' * (Wird nur verwendet, wenn das Property noch nicht exisitert. Weitere Infos unter CurrentDb.CreateProperty) ' * @param Variant Wert des Property ' * @return void ' */ Public Function changeProperty(ByVal iname As String, ByVal itype As Variant, ByVal iValue As Variant) As Boolean Const C_PORPERTY_NOT_FOUND = 3270 Dim pProprty As Property On Error GoTo Err_Handler CurrentDb.Properties(iname) = iValue ChangeProperty = True Exit_Handler: Exit Function Err_Handler: If Err = C_PORPERTY_NOT_FOUND Then ' Property not found. Set pProprty = CurrentDb.CreateProperty(iname, itype, iValue) CurrentDb.Properties.append pProprty Resume Next Else ChangeProperty = False Resume Exit_Handler End If End Function