Dynamic Form Items with Dynamic Validation

I have been working on this for about a week now, and still have not been able to figure this out.

I have a 100% ajax form that changes elements based on multiple dropdowns, dialogs etc, that’s all working fine.

I am into the phase of validating user input, and I can’t for the life of me figure out how to have dynamic custom validation on form elements that don’t exist as part of a model. Certain parts of the app allow higher level users to define the validation rules for other parts of the form and it stores these rules into the database. How do I draw those validation rules from the database and apply them to dynamically called form items? Is there some sort of validation routine I can overwrite or something?

If anyone needs my code to better understand this I can try to pass along the relevant parts.


Hey i know this thread is pretty old but did you ever find a solution, im trying to achieve something very similar!