FUNCTION:  Float.maxFloat

Float.maxFloat(value)
 
The Float.maxFloat function returns the maximum (biggest) single-precision floating-point number that is supported by the browser.
 
The companion Float.minFloat function returns the minimum (smallest) nonzero single-precision floating-point number that is supported by the browser.
 
If the browser does not support floating-point arithmetic operations, then the browser will not recognize the Float Library, nor any of the member functions. In this case, the Float.maxFloat function returns invalid.
 
This function does not take a parameter.
 
Code for MaxFloatExample.wml
<?xml version="1.0"?>
<!DOCTYPE wml PUBLIC "-//WAPFORUM//DTD WML 1.1//EN"
"http://www.WAPforum.org/DTD/wml_1.1.xml">
<wml>

<card id="card1">
   <p>
   sqrt example
   </p>
   <do type="accept">
      <go href="MaxFloatExample.wmls#findmaxfloat()" />
   </do>
</card>

<card id="card2">
<p>
   maximum = $(max)
   <br />
   minimum = $(min)
</p>
</card>

</wml>

 
Code for MaxFloatExample.wmls
extern function findmaxfloat()
{
   var maxresult = Float.maxFloat();
   WMLBrowser.setVar("max", maxresult);
   var minresult = Float.minFloat();
   WMLBrowser.setVar("min", minresult);
   WMLBrowser.go("MaxFloatExample.wml#card2");
};


Copyright 1999-2001 by Infinite Software Solutions, Inc. All rights reserved.
Trademark Information