AVeryNiceWeb

What does converting to a float mean?

What does converting to a float mean?

Postby admin » Tue May 23, 2017 7:59 pm

When somebody tells you that you need to convert to a float it means that a second stage or more is required to process a string. For example:

Q.- I want to remove commas from the string and calculate those amount using javascript.

For example : I have those two values -

400,000.00
200,000.00

Now I want to remove commas from those string and want the total of those amount.

A.- To remove the commas, you'll need to use replace on the string. To convert to a float so you can do the maths, you'll need parseFloat:
The AVNW Support Team
http://www.AVeryNiceWeb.com

We also have great domain names for your next website. Go through the list and make an offer now!

Shopping for a new website? See our design deals.

How much is your website worth? Get a free estimate.

And, if our post has provided you with great information, there are a few ways you can show your appreciation:
  1. Like us on Facebook
  2. Post a review.- Posting a good review about this site could help us provide improved support.

Thank You!
User avatar
admin
Site Admin
 
Posts: 481
Joined: Sun Jan 12, 2014 11:18 pm
Location: New York City

Return to Support

Who is online

Users browsing this forum: No registered users and 2 guests

cron