public override void UpdateAttributes(string controlPrefix, NameValueCollection postedFormValues, CustomQuestionProperties props) { if (!(bool)props.GetAttributeBool(_parentChangeFlagGuid)) { if (props.GetAttribute(_valueGuid) as string != postedFormValues[controlPrefix]) { props.UpdateAttribute(_manualChangeFlagGuid, true); } props.UpdateAttribute(_valueGuid, postedFormValues[controlPrefix]); } }
public override void InputChanged(CustomQuestionInput input, object oldValue, CustomQuestionProperties props) { if (input.InputTypeId == _defaultValueGuid) { if (!(bool)props.GetAttributeBool(_manualChangeFlagGuid)) { props.UpdateAttribute(_valueGuid, input.Value); props.UpdateAttribute(_parentChangeFlagGuid, true); } } else if (input.InputTypeId == _maxLengthGuid) { props.UpdateAttribute(_maxLengthGuid, input.Value); } }