DODEFAULT() *** Unbind the control and save the controlsource to a special property IF NOT EMPTY( This.ControlSource ) This.cControlSource = This.ControlSource This.ControlSource = '' ENDIF This.Format = 'D' This.Value = {}Then I added a method called UpdateControlSource that is called from the control's Valid and UpdateValue that is called from its Refresh. Code like this in RefreshValue():
LOCAL ltValue IF NOT EMPTY( This.cControlSource ) ltValue = EVALUATE( This.cControlSource ) *** Update the control's value from its cControlSource IF EMPTY( NVL( ltValue, {/:} ) ) This.Value = {} ELSE IF VARTYPE( ltValue ) = 'T' This.Value = TTOD( ltValue ) ELSE This.Value = ltValue ENDIF ENDIF ELSE This.Value = {} ENDIFHTH.