Skip to main content
the_starship
Participant
October 16, 2022
Answered

I imported a CSV and the trailing zero is missing

  • October 16, 2022
  • 1 reply
  • 317 views

I display a lot of pricing data on my youtube channel. And I recently discovered that you can import a CSV of data and it will change the text boxes based on that data supplied. 

The issue that I'm running into is that the prices are missing trailing zeros. 

For example 237.50 will be imported as 237.5 and there is no way to just add that zero. 

How can I make sure that that trailing zero is present ?

I had tried to use the toFixed() expression but it's telling me that it's not a valid function (I'm guessing this is because the source text is coming from the CSV.) 

 

This topic has been closed for replies.
Correct answer Dan Ebberts

You might have to do:

parseFloat(link_to_your_number).toFixed(2)

1 reply

Dan Ebberts
Community Expert
Dan EbbertsCommunity ExpertCorrect answer
Community Expert
October 17, 2022

You might have to do:

parseFloat(link_to_your_number).toFixed(2)
the_starship
Participant
October 19, 2022

Much appreciated! thank you