Chris Martin created FLEX-34878:
-----------------------------------

             Summary: error property of NumberFormatter returns null and not 
it's default value
                 Key: FLEX-34878
                 URL: https://issues.apache.org/jira/browse/FLEX-34878
             Project: Apache Flex
          Issue Type: Improvement
            Reporter: Chris Martin
            Assignee: Chris Martin
            Priority: Trivial


Steps to reproduce:

Build an application from the following code:
{code:actionscript}
<?xml version="1.0" encoding="utf-8"?>
<mx:WindowedApplication xmlns:mx="http://www.adobe.com/2006/mxml"; 
layout="absolute" creationComplete="onCC();">
    <mx:Script>
    <![CDATA[
        import mx.formatters.NumberFormatter;

        private function onCC():void
        {
            var nf:NumberFormatter = new NumberFormatter();
            nf.precision = 2;
            resourceManager.localeChain = ['zh-Hans'];
            trace("number:"+nf.format(1/3));
            trace("error: " + nf.error);
        } 
    ]]>
    </mx:Script>
</mx:WindowedApplication>
{code}

Compile the application but do not compile in a locale resource set for 
zh-Hans. Only compile in 'en_US'.

Test the application and note that the first trace statement will return blank 
and the second trace statement of the error property returns null.

Because the zh-Hans locale was not compiled in we are unable to know what 
language to use to display the default error message of "Invalid format".

Would like to add in a comment into the asdocs informing using that the error 
property cannot return the default values in the requested locale has not been 
compiled in.




--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to