# Imput (decimal) & State (number)

**URL:** <https://forum.bubble.io/t/imput-decimal-state-number/82338>\
**Category:** Need help\
**Created:** [March 18, 2020, 2:07pm UTC](https://forum.bubble.io/t/imput-decimal-state-number/82338 "2020-03-18T14:07:06Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![audric](https://avatars.discourse-cdn.com/v4/letter/a/13edae/32.png) [@audric](https://forum.bubble.io/u/audric)\
**Post date:** [March 18, 2020, 2:07pm UTC](https://forum.bubble.io/t/imput-decimal-state-number/82338/1 "2020-03-18T14:07:06Z")

</div>

Hello everybody,

I need your help to solve a problem in my app. 🙂

In my result page, I used a state to calculate a new data to show in a text element. The state is config like this as a number.  
 ![Capture d’écran 2020-03-18 à 15.18.20](https://us1.discourse-cdn.com/bubble/original/3X/3/7/377c3221fa5c6c163d0db34edf2b09622a4b8dab.png)

Now I would like to let the user modify this state to change the result. So I created an input field (Decimal) with the state as initial content. And the user can change the input. When he does that, a workflow is running to calculate the result with the new data.

When I open the page, the number in the input field is like this “1.5”. But when i change it, for exemple to “1.6” calculation are equal to 0. I need to enter “1,6” if I want the calculation to run …

It is not very user-friendly for the user … Do you have an idea to solve this ?

Thanks a lot,  
Audric

---

<div class="post-metadata">

**Author:** ![audric](https://avatars.discourse-cdn.com/v4/letter/a/13edae/32.png) [@audric](https://forum.bubble.io/u/audric)\
**Post date:** [March 23, 2020, 3:54pm UTC](https://forum.bubble.io/t/imput-decimal-state-number/82338/2 "2020-03-23T15:54:48Z")

</div>

Hello there,

Do you have an idea what might the problem between . and , ?

Thanks a lot

---

<div class="post-metadata">

**Author:** ![vini\_brito](https://sea1.discourse-cdn.com/bubble/user_avatar/forum.bubble.io/vini_brito/32/22187_2.png) [@vini\_brito](https://forum.bubble.io/u/vini_brito)\
**Post date:** [March 23, 2020, 10:15pm UTC](https://forum.bubble.io/t/imput-decimal-state-number/82338/3 "2020-03-23T22:15:25Z")

</div>

In some countries decimals are separated by comma (1,6), in others by dot (1.6).  
Sometimes the user’s browser gets confused on which to use in an input.

---

<div class="post-metadata">

**Author:** ![audric](https://avatars.discourse-cdn.com/v4/letter/a/13edae/32.png) [@audric](https://forum.bubble.io/u/audric)\
**Post date:** [March 24, 2020, 9:12am UTC](https://forum.bubble.io/t/imput-decimal-state-number/82338/4 "2020-03-24T09:12:14Z")

</div>

Hello Vini,

I could understand that. But how can you explain that **in the same page** , a calculation understand a “1.3” and calculations runs correctly, and when you change the input to “1.4”, the calculation fail … and work again if you change to “1,3” ?

---

<div class="post-metadata">

**Author:** ![vini\_brito](https://sea1.discourse-cdn.com/bubble/user_avatar/forum.bubble.io/vini_brito/32/22187_2.png) [@vini\_brito](https://forum.bubble.io/u/vini_brito)\
**Post date:** [March 25, 2020, 6:28am UTC](https://forum.bubble.io/t/imput-decimal-state-number/82338/5 "2020-03-25T06:28:26Z")

</div>

Not from the top of my head 🤔  
This is the kind of thing that would be better to see it happening in a page, if it’s possible to isolate that in an example app and share it then please do (:

---

<div class="post-metadata">

**Author:** ![Lucien](https://sea1.discourse-cdn.com/bubble/user_avatar/forum.bubble.io/lucien/32/58216_2.png) [@Lucien](https://forum.bubble.io/u/Lucien)\
**Post date:** [May 2, 2020, 7:56am UTC](https://forum.bubble.io/t/imput-decimal-state-number/82338/6 "2020-05-02T07:56:21Z")

</div>

I observed some weirdness and confusion between “,” and “.” on my end too. Even if I was formatting the decimal with a comma it would still show a dot. What fixed it was to check “show thousand separator” (even though my numbers do not exceed 999) 🤷🏻‍♂️

I mean fixed for me, as I want to use commas. Hopefully that can do the trick for you too.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/bubble/original/3X/2/8/2847faa74692c2ffa5d939d3dc3724cdd060d247.png) [@system](https://forum.bubble.io/u/system)\
**Post date:** [May 27, 2020, 2:07pm UTC](https://forum.bubble.io/t/imput-decimal-state-number/82338/7 "2020-05-27T14:07:11Z")

</div>

This topic was automatically closed after 70 days. New replies are no longer allowed.
