Checking Whether Mobile Devices Support Floating-point Numbers and Operations: float() Function

Preferences - Do not show ads

The float() function returns a Boolean value indicating whether a mobile device supports floating-point numbers and operations. Here is an example:


var supportFloatType = Lang.float();


If the mobile device supports floating-point numbers and operations, the supportFloatType variable will contain the value true.

Note that if the return value of the float() function is false, the functions listed below will not work and all of them will return the invalid value if they are called:

  • All functions in the Float standard library

  • isFloat() function of the Lang standard library

  • parseFloat() function of the Lang standard library


Page 58 of 71 Previous Page | Next Page
Contents at a Glance
Print this Web Page | | Back to Top

Feedback Form (Expand)

What do you think about this web page?






WMLScript Tutorial Table of Contents WMLScript Tutorial Contents at a Glance Preferences - Change Color Scheme Preferences - Do Not Show Ads Previous Page Next Page