11-13-2024 12:46 PM
I would like to make a numeric control blank after entering in a value. Is that possible?
11-13-2024 12:57 PM
Numeric controls by their nature always show a number. They can't show "blank".
One alternate options is that you could use a String control instead, and just generate errors if someone puts something into it that can't be parsed as a number.
Without knowing your real objective here though it's hard to suggest other possible alternatives. What are you really trying to do overall?
11-13-2024 04:02 PM
@Kyle97330 wrote:
Numeric controls by their nature always show a number. They can't show "blank".
One alternate options is that you could use a String control instead, and just generate errors if someone puts something into it that can't be parsed as a number.
Or you can use the String "Key Down?" event to filter out unwanted Char to mimic a numeric control.
11-13-2024 05:19 PM
You could make the font color the same as the background color except when hovering with the mouse over it.
11-13-2024 05:23 PM
@altenbach wrote:
You could make the font color the same as the background color except when hovering with the mouse over it.
Never say never... that is some out-of-the-box thinking. 😁
11-13-2024 05:33 PM
@altenbach wrote:
You could make the font color the same as the background color except when hovering with the mouse over it.
Do you catch the value change event also? OP wants blank "after entering in a value".
We can't test your picture 😉
11-13-2024 07:36 PM
@zou wrote:
Do you catch the value change event also? OP wants blank "after entering in a value".
We can't test your picture 😉
Well, that could easily be implemented with a bit more code once we have all requirements. We don't!
Currently the indicator is blank unless the mouse hovers over it. Should the user be able to enter a new value later or never again? In my case, we see what is being entered while the mouse is over it. Also how should the control look like before a value is entered?
It would be simple to expand the code ... I still don't see the purpose of all this! How does the operator benefit from a blank control?
11-13-2024 10:56 PM
1. mouse enter is not a proper event. Does touch screen trigger mouse enter event? What if user use the Tab key instead of mouse? I would use KeyFocus event if I could 🙂
2. mouse leave is not proper event either. Think about this scenario: user start to enter number, but before he finish, he moves the cursor out of the way, and then blank.
11-13-2024 11:32 PM
@Kyle97330 wrote:
Numeric controls by their nature always show a number. They can't show "blank".
Not completely true. There is a hidden/unofficial property "HideText" that does exactly that.
11-14-2024 04:04 AM
@Martin_Henz wrote:
@Kyle97330 wrote:
Numeric controls by their nature always show a number. They can't show "blank".
Not completely true. There is a hidden/unofficial property "HideText" that does exactly that.
Wait, what?