<html>
<head>
<link href="mmres://user_interface_reference.css" rel="stylesheet" type="text/css">
<title>LSPARSENUMBER</title>
</head>
<body bgcolor="#FFFFFF" text="#000000">
   <div id="Description">
   <table cellpadding="0" cellspacing="0" border="0" width="100%" class="main">
      <tr> 
         <td valign="top" class="name">LSPARSENUMBER</td>
         <td valign="top" nowrap class="compatibility">&nbsp;</td>
      </tr>
      <tr>
         <td colspan="2" class="divider"><img src="dwres:18084" width="100%" height="1"></td>
      </tr>


    </td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="description"><span class="title">Description</span>
<p>
Converts a string that is a valid numeric representation in the current locale into a formatted number.
</p>
    </td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="CLEARSEPARATION">&nbsp;</td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="description"><span class="title">Returns</span>
<p>
A formatted number that matches the value of the string.
</p>
    </td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="CLEARSEPARATION">&nbsp;</td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="description"><span class="title">Category</span>
<p>
International functions, String functions
</p>
    </td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="CLEARSEPARATION">&nbsp;</td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="description"><span class="title">Function syntax</span><pre>LSParseNumber(string)
</pre>    </td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="CLEARSEPARATION">&nbsp;</td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="description"><span class="title">See also</span>
<p>
LSParseDateTime, SetLocale; "Locales" in Chapter&#160;17, "Developing Globalized Applications" in ColdFusion MX Developer's Guide
</p>
    </td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="CLEARSEPARATION">&nbsp;</td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="description"><span class="title">History</span>
<p>
ColdFusion&#160;MX: Changed formatting behavior: this function might return different formatting than in earlier releases. This function uses Java standard locale formatting rules on all platforms. 
</p>
    </td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="CLEARSEPARATION">&nbsp;</td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="description"><span class="title">Parameters</span>
<p>

</p>
    </td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="CLEARSEPARATION">&nbsp;</td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="description"><span class="title">Usage</span>
<p>
This function uses Java standard locale formatting rules on all platforms.
</p>

<p>
To set the default display format of date, time, number, and currency values, use the SetLocale function. 
</p>
    </td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="CLEARSEPARATION">&nbsp;</td>
  </tr>
  <tr>
    <td valign="top" colspan="2" class="description"><span class="title">Example</span><pre>&lt;h3&gt;LSParseNumber Example&lt;/h3&gt;
&lt;p&gt;LSParseNumber converts a locale-specific string to a number. 
Returns the number matching the value of string. 
&lt;!--- loop through a list of locales and show number values ---&gt;
&lt;cfloop LIST = &quot;#Server.Coldfusion.SupportedLocales#&quot;
index = &quot;locale&quot; delimiters = &quot;,&quot;&gt;
   &lt;cfset oldlocale = SetLocale(locale)&gt;

   &lt;cfoutput&gt;&lt;p&gt;&lt;B&gt;&lt;I&gt;#locale#&lt;/I&gt;&lt;/B&gt;&lt;br&gt;
      #LSNumberFormat(-1234.5678, &quot;_________&quot;)#&lt;br&gt;
      #LSNumberFormat(-1234.5678, &quot;_________.___&quot;)#&lt;br&gt;
      #LSNumberFormat(1234.5678, &quot;_________&quot;)#&lt;br&gt;
      #LSNumberFormat(1234.5678, &quot;_________.___&quot;)#&lt;br&gt;      
      #LSNumberFormat(1234.5678, &quot;$_(_________.___)&quot;)#&lt;br&gt;      
      #LSNumberFormat(-1234.5678, &quot;$_(_________.___)&quot;)#&lt;br&gt;      
      #LSNumberFormat(1234.5678, &quot;+_________.___&quot;)#&lt;br&gt;      
      #LSNumberFormat(1234.5678, &quot;-_________.___&quot;)#&lt;br&gt;      
      The actual number: 
         #LSParseNumber(LSNumberFormat(1234.5678, &quot;_________&quot;))#&lt;br&gt;
      &lt;hr noshade&gt;
   &lt;/cfoutput&gt;
&lt;/cfloop&gt;
</pre>
         </td>
      </tr>
   </table>
   </div>
<div id="STRING">
<table border="0" cellspacing="0" cellpadding="0" width="100%">
<tr>  
<td valign="top" class="name">STRING</td>
  <td valign="top" nowrap class="compatibility">&nbsp;</td>
  </tr>
  <tr>
  <td colspan="2" class="divider"><img src="dwres:18084" width="100%" height="1"></td>
  </tr>


<p>A string or a variable that contains one</p>

  </td>
  </tr>
  </table>
</div>

  </body>
</html>
