AnsweredAssumed Answered

Passing arguments to javascript for field validation

Question asked by wurstgelee on Sep 6, 2012
Latest reply on Sep 7, 2012 by wurstgelee
I´m trying to do some field validation in a workflow form.

As far as I understand, it is possible to pass arguments (@param args) to a validation handler (the javascript function).

My validation handler implementation for the field validation currently looks like this:

<field id="aiwf:itemDescription2" set="InvestItems" label="" mandatory="true">
            <control template="/custom-textfield.ftl" />
              <constraint type="MANDATORY" validation-handler="Alfresco.forms.validation.validateStringLength" event="keyup" silent="false" message="test1">

I would like to pass the valid min and max string length to the validateStringLength function. How can I archieve this? Or isn´t this possible?

Please help me! ;)