I have a problem. When i get value from TextMesPRO the progress bar not fill. Ad Pic01 - 03.
But when i write value directly in script, the progress bar fill without problem Ad Pic04 -05.
I am beginner… Thank you for your help…
I have a problem. When i get value from TextMesPRO the progress bar not fill. Ad Pic01 - 03.
But when i write value directly in script, the progress bar fill without problem Ad Pic04 -05.
I am beginner… Thank you for your help…
parsing the value from a Text GUI element makes no sense anyway - why would you do it that way? Plus you’re inviting all kinds of issues with localization, etc.
What you need to do is just use the same data to fill your slider as you used to populate the text element.
This ^ ^ ^ ^
To the greatest extent possible, always treat all Unity properties and fields as write-only, especially if they are text.
This means if you have a datasource X and it needs to be displayed in two places A and B, always structure it as:
X → A
X → B
You have it structured it as:
X → A → B
Which means that if A changes, then B breaks. ![]()
Well, while I agree with that statement, it’s not generally valid. This looks like some kind of industrial process visualization. So the GUI may have input fields where the user / operator has to enter certain values. Yes, localization can be an issue, but we have localization so people can enter values in their local culture.
I can’t see any direct error (besides I would always use TryParse if I have to parse user input and I would not parse the same value multiple times
)