Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    Problem with listGrid regexp validation

    Hi, with 8.2 I'm trying to use a regexp validator that restricts input to letters numbers or spaces. The following validation definition works fine for a Dynamic Form.

    Code:
           <validator type="regexp" 
                   expression="^[a-zA-Z0-9 ]+$">
                 <errorMessage>
                     	<spring:message code="exception.alphanumeric.validation"/>
                    </errorMessage>
            </validator>
    But, when I try it on a ListGrid with autoSaveEdits:true, I get an exception. It seems to only throw this exception when the entered value is invalid. But, I'd prefer obviously to show an accurate validation message instead of a generic error message. Here is the exception. Any idea what is going on? I tried to recreate using this sample and everything worked fine using the sample: http://www.smartclient.com/docs/8.2/a/system/reference/SmartClient_Explorer.html#dataValidation

    Code:
    12:23:34.918:IFCS3:WARN:Log:TypeError: Object #<Object> has no method 'getValue'
        unnamed() @ 
        unnamed() @ js/at_js_static.js?build=local_dev:18:77
        isc.defineClass.addProperties.validateRow() @ dpt.form#:466:14
        ListGrid.saveEdits()
        ListGrid.saveAllEdits()
        eval()
        FormItem._fireStandardHandler()
        FormItem.handleClick()
        Class.invokeSuper()
        Class.Super()
        ButtonItem.handleClick()

    #2
    It looks like this crash is happening in your code, in method called from an override of listGrid.validateRow(). You might take a look at other browser's stack traces or try breaking on error in Firebug or Chrome's tools to see where precisely this is happening.

    Comment


      #3
      Thanks, figured out the problem in my code.

      Comment

      Working...
      X