• Custom Converters on a djTextBox?

    By Alex J Woodall 1 decade ago

    I'm trying to add a custom converter to a djTextBox, has anyone done this successfully? Here is the code I'm using, when you save these two fields they both send a value to the back end document but only the inputText actually does the convert.

     

     

    <xp:inputText id="inputFIELD1" value="#{document1.FIELD1}">
    
    <xp:this.converter>
    
    <xp:customConverter getAsObject="#{javascript:@Name('[Canonicalize]', value)}"
    
    getAsString="#{javascript:@Name('[Abbreviate]', value)}">
    
    </xp:customConverter>
    
    </xp:this.converter>
    
    </xp:inputText>
    
    <xe:djTextBox id="inputFIELD2" value="#{document1.FIELD2}">
    
    <xp:this.converter>
    
    <xp:customConverter getAsObject="#{javascript:@Name('[Canonicalize]', value)}"
    
    getAsString="#{javascript:@Name('[Abbreviate]', value)}">
    
    </xp:customConverter>
    
    </xp:this.converter>
    
    </xe:djTextBox>